module Stratosphere.CloudFront.StreamingDistribution.TrustedSignersProperty (
TrustedSignersProperty(..), mkTrustedSignersProperty
) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import Stratosphere.ResourceProperties
import Stratosphere.Value
data TrustedSignersProperty
=
TrustedSignersProperty {TrustedSignersProperty -> ()
haddock_workaround_ :: (),
TrustedSignersProperty -> Maybe (ValueList Text)
awsAccountNumbers :: (Prelude.Maybe (ValueList Prelude.Text)),
TrustedSignersProperty -> Value Bool
enabled :: (Value Prelude.Bool)}
deriving stock (TrustedSignersProperty -> TrustedSignersProperty -> Bool
(TrustedSignersProperty -> TrustedSignersProperty -> Bool)
-> (TrustedSignersProperty -> TrustedSignersProperty -> Bool)
-> Eq TrustedSignersProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: TrustedSignersProperty -> TrustedSignersProperty -> Bool
== :: TrustedSignersProperty -> TrustedSignersProperty -> Bool
$c/= :: TrustedSignersProperty -> TrustedSignersProperty -> Bool
/= :: TrustedSignersProperty -> TrustedSignersProperty -> Bool
Prelude.Eq, Int -> TrustedSignersProperty -> ShowS
[TrustedSignersProperty] -> ShowS
TrustedSignersProperty -> String
(Int -> TrustedSignersProperty -> ShowS)
-> (TrustedSignersProperty -> String)
-> ([TrustedSignersProperty] -> ShowS)
-> Show TrustedSignersProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> TrustedSignersProperty -> ShowS
showsPrec :: Int -> TrustedSignersProperty -> ShowS
$cshow :: TrustedSignersProperty -> String
show :: TrustedSignersProperty -> String
$cshowList :: [TrustedSignersProperty] -> ShowS
showList :: [TrustedSignersProperty] -> ShowS
Prelude.Show)
mkTrustedSignersProperty ::
Value Prelude.Bool -> TrustedSignersProperty
mkTrustedSignersProperty :: Value Bool -> TrustedSignersProperty
mkTrustedSignersProperty Value Bool
enabled
= TrustedSignersProperty
{haddock_workaround_ :: ()
haddock_workaround_ = (), enabled :: Value Bool
enabled = Value Bool
enabled,
awsAccountNumbers :: Maybe (ValueList Text)
awsAccountNumbers = Maybe (ValueList Text)
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties TrustedSignersProperty where
toResourceProperties :: TrustedSignersProperty -> ResourceProperties
toResourceProperties TrustedSignersProperty {Maybe (ValueList Text)
()
Value Bool
haddock_workaround_ :: TrustedSignersProperty -> ()
awsAccountNumbers :: TrustedSignersProperty -> Maybe (ValueList Text)
enabled :: TrustedSignersProperty -> Value Bool
haddock_workaround_ :: ()
awsAccountNumbers :: Maybe (ValueList Text)
enabled :: Value Bool
..}
= ResourceProperties
{awsType :: Text
awsType = Text
"AWS::CloudFront::StreamingDistribution.TrustedSigners",
supportsTags :: Bool
supportsTags = Bool
Prelude.False,
properties :: Object
properties = [Item Object] -> Object
forall l. IsList l => [Item l] -> l
Prelude.fromList
([(Key, Value)] -> [(Key, Value)] -> [(Key, Value)]
forall a. Semigroup a => a -> a -> a
(Prelude.<>)
[Key
"Enabled" Key -> Value Bool -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= Value Bool
enabled]
([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[Key -> ValueList 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
"AwsAccountNumbers" (ValueList Text -> (Key, Value))
-> Maybe (ValueList Text) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (ValueList Text)
awsAccountNumbers]))}
instance JSON.ToJSON TrustedSignersProperty where
toJSON :: TrustedSignersProperty -> Value
toJSON TrustedSignersProperty {Maybe (ValueList Text)
()
Value Bool
haddock_workaround_ :: TrustedSignersProperty -> ()
awsAccountNumbers :: TrustedSignersProperty -> Maybe (ValueList Text)
enabled :: TrustedSignersProperty -> Value Bool
haddock_workaround_ :: ()
awsAccountNumbers :: Maybe (ValueList Text)
enabled :: Value Bool
..}
= [(Key, Value)] -> Value
JSON.object
([Item [(Key, Value)]] -> [(Key, Value)]
forall l. IsList l => [Item l] -> l
Prelude.fromList
([(Key, Value)] -> [(Key, Value)] -> [(Key, Value)]
forall a. Semigroup a => a -> a -> a
(Prelude.<>)
[Key
"Enabled" Key -> Value Bool -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= Value Bool
enabled]
([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[Key -> ValueList 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
"AwsAccountNumbers" (ValueList Text -> (Key, Value))
-> Maybe (ValueList Text) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (ValueList Text)
awsAccountNumbers])))
instance Property "AwsAccountNumbers" TrustedSignersProperty where
type PropertyType "AwsAccountNumbers" TrustedSignersProperty = ValueList Prelude.Text
set :: PropertyType "AwsAccountNumbers" TrustedSignersProperty
-> TrustedSignersProperty -> TrustedSignersProperty
set PropertyType "AwsAccountNumbers" TrustedSignersProperty
newValue TrustedSignersProperty {Maybe (ValueList Text)
()
Value Bool
haddock_workaround_ :: TrustedSignersProperty -> ()
awsAccountNumbers :: TrustedSignersProperty -> Maybe (ValueList Text)
enabled :: TrustedSignersProperty -> Value Bool
haddock_workaround_ :: ()
awsAccountNumbers :: Maybe (ValueList Text)
enabled :: Value Bool
..}
= TrustedSignersProperty
{awsAccountNumbers :: Maybe (ValueList Text)
awsAccountNumbers = ValueList Text -> Maybe (ValueList Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "AwsAccountNumbers" TrustedSignersProperty
ValueList Text
newValue, ()
Value Bool
haddock_workaround_ :: ()
enabled :: Value Bool
haddock_workaround_ :: ()
enabled :: Value Bool
..}
instance Property "Enabled" TrustedSignersProperty where
type PropertyType "Enabled" TrustedSignersProperty = Value Prelude.Bool
set :: PropertyType "Enabled" TrustedSignersProperty
-> TrustedSignersProperty -> TrustedSignersProperty
set PropertyType "Enabled" TrustedSignersProperty
newValue TrustedSignersProperty {Maybe (ValueList Text)
()
Value Bool
haddock_workaround_ :: TrustedSignersProperty -> ()
awsAccountNumbers :: TrustedSignersProperty -> Maybe (ValueList Text)
enabled :: TrustedSignersProperty -> Value Bool
haddock_workaround_ :: ()
awsAccountNumbers :: Maybe (ValueList Text)
enabled :: Value Bool
..}
= TrustedSignersProperty {enabled :: Value Bool
enabled = PropertyType "Enabled" TrustedSignersProperty
Value Bool
newValue, Maybe (ValueList Text)
()
haddock_workaround_ :: ()
awsAccountNumbers :: Maybe (ValueList Text)
haddock_workaround_ :: ()
awsAccountNumbers :: Maybe (ValueList Text)
..}