module Stratosphere.PCAConnectorAD.Template.ExtensionsV2Property (
        module Exports, ExtensionsV2Property(..), mkExtensionsV2Property
    ) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import {-# SOURCE #-} Stratosphere.PCAConnectorAD.Template.ApplicationPoliciesProperty as Exports
import {-# SOURCE #-} Stratosphere.PCAConnectorAD.Template.KeyUsageProperty as Exports
import Stratosphere.ResourceProperties
data ExtensionsV2Property
  = -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-pcaconnectorad-template-extensionsv2.html>
    ExtensionsV2Property {ExtensionsV2Property -> ()
haddock_workaround_ :: (),
                          -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-pcaconnectorad-template-extensionsv2.html#cfn-pcaconnectorad-template-extensionsv2-applicationpolicies>
                          ExtensionsV2Property -> Maybe ApplicationPoliciesProperty
applicationPolicies :: (Prelude.Maybe ApplicationPoliciesProperty),
                          -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-pcaconnectorad-template-extensionsv2.html#cfn-pcaconnectorad-template-extensionsv2-keyusage>
                          ExtensionsV2Property -> KeyUsageProperty
keyUsage :: KeyUsageProperty}
  deriving stock (ExtensionsV2Property -> ExtensionsV2Property -> Bool
(ExtensionsV2Property -> ExtensionsV2Property -> Bool)
-> (ExtensionsV2Property -> ExtensionsV2Property -> Bool)
-> Eq ExtensionsV2Property
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: ExtensionsV2Property -> ExtensionsV2Property -> Bool
== :: ExtensionsV2Property -> ExtensionsV2Property -> Bool
$c/= :: ExtensionsV2Property -> ExtensionsV2Property -> Bool
/= :: ExtensionsV2Property -> ExtensionsV2Property -> Bool
Prelude.Eq, Int -> ExtensionsV2Property -> ShowS
[ExtensionsV2Property] -> ShowS
ExtensionsV2Property -> String
(Int -> ExtensionsV2Property -> ShowS)
-> (ExtensionsV2Property -> String)
-> ([ExtensionsV2Property] -> ShowS)
-> Show ExtensionsV2Property
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> ExtensionsV2Property -> ShowS
showsPrec :: Int -> ExtensionsV2Property -> ShowS
$cshow :: ExtensionsV2Property -> String
show :: ExtensionsV2Property -> String
$cshowList :: [ExtensionsV2Property] -> ShowS
showList :: [ExtensionsV2Property] -> ShowS
Prelude.Show)
mkExtensionsV2Property :: KeyUsageProperty -> ExtensionsV2Property
mkExtensionsV2Property :: KeyUsageProperty -> ExtensionsV2Property
mkExtensionsV2Property KeyUsageProperty
keyUsage
  = ExtensionsV2Property
      {haddock_workaround_ :: ()
haddock_workaround_ = (), keyUsage :: KeyUsageProperty
keyUsage = KeyUsageProperty
keyUsage,
       applicationPolicies :: Maybe ApplicationPoliciesProperty
applicationPolicies = Maybe ApplicationPoliciesProperty
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties ExtensionsV2Property where
  toResourceProperties :: ExtensionsV2Property -> ResourceProperties
toResourceProperties ExtensionsV2Property {Maybe ApplicationPoliciesProperty
()
KeyUsageProperty
haddock_workaround_ :: ExtensionsV2Property -> ()
applicationPolicies :: ExtensionsV2Property -> Maybe ApplicationPoliciesProperty
keyUsage :: ExtensionsV2Property -> KeyUsageProperty
haddock_workaround_ :: ()
applicationPolicies :: Maybe ApplicationPoliciesProperty
keyUsage :: KeyUsageProperty
..}
    = ResourceProperties
        {awsType :: Text
awsType = Text
"AWS::PCAConnectorAD::Template.ExtensionsV2",
         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
"KeyUsage" Key -> KeyUsageProperty -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= KeyUsageProperty
keyUsage]
                           ([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
                              [Key -> ApplicationPoliciesProperty -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"ApplicationPolicies"
                                 (ApplicationPoliciesProperty -> (Key, Value))
-> Maybe ApplicationPoliciesProperty -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe ApplicationPoliciesProperty
applicationPolicies]))}
instance JSON.ToJSON ExtensionsV2Property where
  toJSON :: ExtensionsV2Property -> Value
toJSON ExtensionsV2Property {Maybe ApplicationPoliciesProperty
()
KeyUsageProperty
haddock_workaround_ :: ExtensionsV2Property -> ()
applicationPolicies :: ExtensionsV2Property -> Maybe ApplicationPoliciesProperty
keyUsage :: ExtensionsV2Property -> KeyUsageProperty
haddock_workaround_ :: ()
applicationPolicies :: Maybe ApplicationPoliciesProperty
keyUsage :: KeyUsageProperty
..}
    = [(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
"KeyUsage" Key -> KeyUsageProperty -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= KeyUsageProperty
keyUsage]
              ([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
                 [Key -> ApplicationPoliciesProperty -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"ApplicationPolicies"
                    (ApplicationPoliciesProperty -> (Key, Value))
-> Maybe ApplicationPoliciesProperty -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe ApplicationPoliciesProperty
applicationPolicies])))
instance Property "ApplicationPolicies" ExtensionsV2Property where
  type PropertyType "ApplicationPolicies" ExtensionsV2Property = ApplicationPoliciesProperty
  set :: PropertyType "ApplicationPolicies" ExtensionsV2Property
-> ExtensionsV2Property -> ExtensionsV2Property
set PropertyType "ApplicationPolicies" ExtensionsV2Property
newValue ExtensionsV2Property {Maybe ApplicationPoliciesProperty
()
KeyUsageProperty
haddock_workaround_ :: ExtensionsV2Property -> ()
applicationPolicies :: ExtensionsV2Property -> Maybe ApplicationPoliciesProperty
keyUsage :: ExtensionsV2Property -> KeyUsageProperty
haddock_workaround_ :: ()
applicationPolicies :: Maybe ApplicationPoliciesProperty
keyUsage :: KeyUsageProperty
..}
    = ExtensionsV2Property
        {applicationPolicies :: Maybe ApplicationPoliciesProperty
applicationPolicies = ApplicationPoliciesProperty -> Maybe ApplicationPoliciesProperty
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "ApplicationPolicies" ExtensionsV2Property
ApplicationPoliciesProperty
newValue, ()
KeyUsageProperty
haddock_workaround_ :: ()
keyUsage :: KeyUsageProperty
haddock_workaround_ :: ()
keyUsage :: KeyUsageProperty
..}
instance Property "KeyUsage" ExtensionsV2Property where
  type PropertyType "KeyUsage" ExtensionsV2Property = KeyUsageProperty
  set :: PropertyType "KeyUsage" ExtensionsV2Property
-> ExtensionsV2Property -> ExtensionsV2Property
set PropertyType "KeyUsage" ExtensionsV2Property
newValue ExtensionsV2Property {Maybe ApplicationPoliciesProperty
()
KeyUsageProperty
haddock_workaround_ :: ExtensionsV2Property -> ()
applicationPolicies :: ExtensionsV2Property -> Maybe ApplicationPoliciesProperty
keyUsage :: ExtensionsV2Property -> KeyUsageProperty
haddock_workaround_ :: ()
applicationPolicies :: Maybe ApplicationPoliciesProperty
keyUsage :: KeyUsageProperty
..}
    = ExtensionsV2Property {keyUsage :: KeyUsageProperty
keyUsage = PropertyType "KeyUsage" ExtensionsV2Property
KeyUsageProperty
newValue, Maybe ApplicationPoliciesProperty
()
haddock_workaround_ :: ()
applicationPolicies :: Maybe ApplicationPoliciesProperty
haddock_workaround_ :: ()
applicationPolicies :: Maybe ApplicationPoliciesProperty
..}