module Stratosphere.Bedrock.Agent.AgentDescriptorProperty (
        AgentDescriptorProperty(..), mkAgentDescriptorProperty
    ) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import Stratosphere.ResourceProperties
import Stratosphere.Value
data AgentDescriptorProperty
  = -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-bedrock-agent-agentdescriptor.html>
    AgentDescriptorProperty {AgentDescriptorProperty -> ()
haddock_workaround_ :: (),
                             -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-bedrock-agent-agentdescriptor.html#cfn-bedrock-agent-agentdescriptor-aliasarn>
                             AgentDescriptorProperty -> Maybe (Value Text)
aliasArn :: (Prelude.Maybe (Value Prelude.Text))}
  deriving stock (AgentDescriptorProperty -> AgentDescriptorProperty -> Bool
(AgentDescriptorProperty -> AgentDescriptorProperty -> Bool)
-> (AgentDescriptorProperty -> AgentDescriptorProperty -> Bool)
-> Eq AgentDescriptorProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: AgentDescriptorProperty -> AgentDescriptorProperty -> Bool
== :: AgentDescriptorProperty -> AgentDescriptorProperty -> Bool
$c/= :: AgentDescriptorProperty -> AgentDescriptorProperty -> Bool
/= :: AgentDescriptorProperty -> AgentDescriptorProperty -> Bool
Prelude.Eq, Int -> AgentDescriptorProperty -> ShowS
[AgentDescriptorProperty] -> ShowS
AgentDescriptorProperty -> String
(Int -> AgentDescriptorProperty -> ShowS)
-> (AgentDescriptorProperty -> String)
-> ([AgentDescriptorProperty] -> ShowS)
-> Show AgentDescriptorProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> AgentDescriptorProperty -> ShowS
showsPrec :: Int -> AgentDescriptorProperty -> ShowS
$cshow :: AgentDescriptorProperty -> String
show :: AgentDescriptorProperty -> String
$cshowList :: [AgentDescriptorProperty] -> ShowS
showList :: [AgentDescriptorProperty] -> ShowS
Prelude.Show)
mkAgentDescriptorProperty :: AgentDescriptorProperty
mkAgentDescriptorProperty :: AgentDescriptorProperty
mkAgentDescriptorProperty
  = AgentDescriptorProperty
      {haddock_workaround_ :: ()
haddock_workaround_ = (), aliasArn :: Maybe (Value Text)
aliasArn = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties AgentDescriptorProperty where
  toResourceProperties :: AgentDescriptorProperty -> ResourceProperties
toResourceProperties AgentDescriptorProperty {Maybe (Value Text)
()
haddock_workaround_ :: AgentDescriptorProperty -> ()
aliasArn :: AgentDescriptorProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
aliasArn :: Maybe (Value Text)
..}
    = ResourceProperties
        {awsType :: Text
awsType = Text
"AWS::Bedrock::Agent.AgentDescriptor",
         supportsTags :: Bool
supportsTags = Bool
Prelude.False,
         properties :: Object
properties = [Item Object] -> Object
forall l. IsList l => [Item l] -> l
Prelude.fromList
                        ([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes [Key -> Value Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"AliasArn" (Value Text -> (Key, Value))
-> Maybe (Value Text) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Text)
aliasArn])}
instance JSON.ToJSON AgentDescriptorProperty where
  toJSON :: AgentDescriptorProperty -> Value
toJSON AgentDescriptorProperty {Maybe (Value Text)
()
haddock_workaround_ :: AgentDescriptorProperty -> ()
aliasArn :: AgentDescriptorProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
aliasArn :: Maybe (Value Text)
..}
    = [(Key, Value)] -> Value
JSON.object
        ([Item [(Key, Value)]] -> [(Key, Value)]
forall l. IsList l => [Item l] -> l
Prelude.fromList
           ([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes [Key -> Value Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"AliasArn" (Value Text -> (Key, Value))
-> Maybe (Value Text) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Text)
aliasArn]))
instance Property "AliasArn" AgentDescriptorProperty where
  type PropertyType "AliasArn" AgentDescriptorProperty = Value Prelude.Text
  set :: PropertyType "AliasArn" AgentDescriptorProperty
-> AgentDescriptorProperty -> AgentDescriptorProperty
set PropertyType "AliasArn" AgentDescriptorProperty
newValue AgentDescriptorProperty {Maybe (Value Text)
()
haddock_workaround_ :: AgentDescriptorProperty -> ()
aliasArn :: AgentDescriptorProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
aliasArn :: Maybe (Value Text)
..}
    = AgentDescriptorProperty {aliasArn :: Maybe (Value Text)
aliasArn = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "AliasArn" AgentDescriptorProperty
Value Text
newValue, ()
haddock_workaround_ :: ()
haddock_workaround_ :: ()
..}