module Stratosphere.Bedrock.FlowVersion.PerformanceConfigurationProperty (
        PerformanceConfigurationProperty(..),
        mkPerformanceConfigurationProperty
    ) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import Stratosphere.ResourceProperties
import Stratosphere.Value
data PerformanceConfigurationProperty
  = -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-bedrock-flowversion-performanceconfiguration.html>
    PerformanceConfigurationProperty {PerformanceConfigurationProperty -> ()
haddock_workaround_ :: (),
                                      -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-bedrock-flowversion-performanceconfiguration.html#cfn-bedrock-flowversion-performanceconfiguration-latency>
                                      PerformanceConfigurationProperty -> Maybe (Value Text)
latency :: (Prelude.Maybe (Value Prelude.Text))}
  deriving stock (PerformanceConfigurationProperty
-> PerformanceConfigurationProperty -> Bool
(PerformanceConfigurationProperty
 -> PerformanceConfigurationProperty -> Bool)
-> (PerformanceConfigurationProperty
    -> PerformanceConfigurationProperty -> Bool)
-> Eq PerformanceConfigurationProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: PerformanceConfigurationProperty
-> PerformanceConfigurationProperty -> Bool
== :: PerformanceConfigurationProperty
-> PerformanceConfigurationProperty -> Bool
$c/= :: PerformanceConfigurationProperty
-> PerformanceConfigurationProperty -> Bool
/= :: PerformanceConfigurationProperty
-> PerformanceConfigurationProperty -> Bool
Prelude.Eq, Int -> PerformanceConfigurationProperty -> ShowS
[PerformanceConfigurationProperty] -> ShowS
PerformanceConfigurationProperty -> String
(Int -> PerformanceConfigurationProperty -> ShowS)
-> (PerformanceConfigurationProperty -> String)
-> ([PerformanceConfigurationProperty] -> ShowS)
-> Show PerformanceConfigurationProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> PerformanceConfigurationProperty -> ShowS
showsPrec :: Int -> PerformanceConfigurationProperty -> ShowS
$cshow :: PerformanceConfigurationProperty -> String
show :: PerformanceConfigurationProperty -> String
$cshowList :: [PerformanceConfigurationProperty] -> ShowS
showList :: [PerformanceConfigurationProperty] -> ShowS
Prelude.Show)
mkPerformanceConfigurationProperty ::
  PerformanceConfigurationProperty
mkPerformanceConfigurationProperty :: PerformanceConfigurationProperty
mkPerformanceConfigurationProperty
  = PerformanceConfigurationProperty
      {haddock_workaround_ :: ()
haddock_workaround_ = (), latency :: Maybe (Value Text)
latency = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties PerformanceConfigurationProperty where
  toResourceProperties :: PerformanceConfigurationProperty -> ResourceProperties
toResourceProperties PerformanceConfigurationProperty {Maybe (Value Text)
()
haddock_workaround_ :: PerformanceConfigurationProperty -> ()
latency :: PerformanceConfigurationProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
latency :: Maybe (Value Text)
..}
    = ResourceProperties
        {awsType :: Text
awsType = Text
"AWS::Bedrock::FlowVersion.PerformanceConfiguration",
         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
"Latency" (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)
latency])}
instance JSON.ToJSON PerformanceConfigurationProperty where
  toJSON :: PerformanceConfigurationProperty -> Value
toJSON PerformanceConfigurationProperty {Maybe (Value Text)
()
haddock_workaround_ :: PerformanceConfigurationProperty -> ()
latency :: PerformanceConfigurationProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
latency :: 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
"Latency" (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)
latency]))
instance Property "Latency" PerformanceConfigurationProperty where
  type PropertyType "Latency" PerformanceConfigurationProperty = Value Prelude.Text
  set :: PropertyType "Latency" PerformanceConfigurationProperty
-> PerformanceConfigurationProperty
-> PerformanceConfigurationProperty
set PropertyType "Latency" PerformanceConfigurationProperty
newValue PerformanceConfigurationProperty {Maybe (Value Text)
()
haddock_workaround_ :: PerformanceConfigurationProperty -> ()
latency :: PerformanceConfigurationProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
latency :: Maybe (Value Text)
..}
    = PerformanceConfigurationProperty
        {latency :: Maybe (Value Text)
latency = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "Latency" PerformanceConfigurationProperty
Value Text
newValue, ()
haddock_workaround_ :: ()
haddock_workaround_ :: ()
..}