module Stratosphere.EC2.LaunchTemplate.NetworkPerformanceOptionsProperty (
NetworkPerformanceOptionsProperty(..),
mkNetworkPerformanceOptionsProperty
) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import Stratosphere.ResourceProperties
import Stratosphere.Value
data NetworkPerformanceOptionsProperty
=
NetworkPerformanceOptionsProperty {NetworkPerformanceOptionsProperty -> ()
haddock_workaround_ :: (),
NetworkPerformanceOptionsProperty -> Maybe (Value Text)
bandwidthWeighting :: (Prelude.Maybe (Value Prelude.Text))}
deriving stock (NetworkPerformanceOptionsProperty
-> NetworkPerformanceOptionsProperty -> Bool
(NetworkPerformanceOptionsProperty
-> NetworkPerformanceOptionsProperty -> Bool)
-> (NetworkPerformanceOptionsProperty
-> NetworkPerformanceOptionsProperty -> Bool)
-> Eq NetworkPerformanceOptionsProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: NetworkPerformanceOptionsProperty
-> NetworkPerformanceOptionsProperty -> Bool
== :: NetworkPerformanceOptionsProperty
-> NetworkPerformanceOptionsProperty -> Bool
$c/= :: NetworkPerformanceOptionsProperty
-> NetworkPerformanceOptionsProperty -> Bool
/= :: NetworkPerformanceOptionsProperty
-> NetworkPerformanceOptionsProperty -> Bool
Prelude.Eq, Int -> NetworkPerformanceOptionsProperty -> ShowS
[NetworkPerformanceOptionsProperty] -> ShowS
NetworkPerformanceOptionsProperty -> String
(Int -> NetworkPerformanceOptionsProperty -> ShowS)
-> (NetworkPerformanceOptionsProperty -> String)
-> ([NetworkPerformanceOptionsProperty] -> ShowS)
-> Show NetworkPerformanceOptionsProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> NetworkPerformanceOptionsProperty -> ShowS
showsPrec :: Int -> NetworkPerformanceOptionsProperty -> ShowS
$cshow :: NetworkPerformanceOptionsProperty -> String
show :: NetworkPerformanceOptionsProperty -> String
$cshowList :: [NetworkPerformanceOptionsProperty] -> ShowS
showList :: [NetworkPerformanceOptionsProperty] -> ShowS
Prelude.Show)
mkNetworkPerformanceOptionsProperty ::
NetworkPerformanceOptionsProperty
mkNetworkPerformanceOptionsProperty :: NetworkPerformanceOptionsProperty
mkNetworkPerformanceOptionsProperty
= NetworkPerformanceOptionsProperty
{haddock_workaround_ :: ()
haddock_workaround_ = (), bandwidthWeighting :: Maybe (Value Text)
bandwidthWeighting = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties NetworkPerformanceOptionsProperty where
toResourceProperties :: NetworkPerformanceOptionsProperty -> ResourceProperties
toResourceProperties NetworkPerformanceOptionsProperty {Maybe (Value Text)
()
haddock_workaround_ :: NetworkPerformanceOptionsProperty -> ()
bandwidthWeighting :: NetworkPerformanceOptionsProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
bandwidthWeighting :: Maybe (Value Text)
..}
= ResourceProperties
{awsType :: Text
awsType = Text
"AWS::EC2::LaunchTemplate.NetworkPerformanceOptions",
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
"BandwidthWeighting" (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)
bandwidthWeighting])}
instance JSON.ToJSON NetworkPerformanceOptionsProperty where
toJSON :: NetworkPerformanceOptionsProperty -> Value
toJSON NetworkPerformanceOptionsProperty {Maybe (Value Text)
()
haddock_workaround_ :: NetworkPerformanceOptionsProperty -> ()
bandwidthWeighting :: NetworkPerformanceOptionsProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
bandwidthWeighting :: 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
"BandwidthWeighting" (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)
bandwidthWeighting]))
instance Property "BandwidthWeighting" NetworkPerformanceOptionsProperty where
type PropertyType "BandwidthWeighting" NetworkPerformanceOptionsProperty = Value Prelude.Text
set :: PropertyType "BandwidthWeighting" NetworkPerformanceOptionsProperty
-> NetworkPerformanceOptionsProperty
-> NetworkPerformanceOptionsProperty
set PropertyType "BandwidthWeighting" NetworkPerformanceOptionsProperty
newValue NetworkPerformanceOptionsProperty {Maybe (Value Text)
()
haddock_workaround_ :: NetworkPerformanceOptionsProperty -> ()
bandwidthWeighting :: NetworkPerformanceOptionsProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
bandwidthWeighting :: Maybe (Value Text)
..}
= NetworkPerformanceOptionsProperty
{bandwidthWeighting :: Maybe (Value Text)
bandwidthWeighting = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "BandwidthWeighting" NetworkPerformanceOptionsProperty
Value Text
newValue, ()
haddock_workaround_ :: ()
haddock_workaround_ :: ()
..}