module Stratosphere.PCAConnectorAD.Template.ExtensionsV3Property (
        module Exports, ExtensionsV3Property(..), mkExtensionsV3Property
    ) 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 ExtensionsV3Property
  = -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-pcaconnectorad-template-extensionsv3.html>
    ExtensionsV3Property {ExtensionsV3Property -> ()
haddock_workaround_ :: (),
                          -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-pcaconnectorad-template-extensionsv3.html#cfn-pcaconnectorad-template-extensionsv3-applicationpolicies>
                          ExtensionsV3Property -> Maybe ApplicationPoliciesProperty
applicationPolicies :: (Prelude.Maybe ApplicationPoliciesProperty),
                          -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-pcaconnectorad-template-extensionsv3.html#cfn-pcaconnectorad-template-extensionsv3-keyusage>
                          ExtensionsV3Property -> KeyUsageProperty
keyUsage :: KeyUsageProperty}
  deriving stock (ExtensionsV3Property -> ExtensionsV3Property -> Bool
(ExtensionsV3Property -> ExtensionsV3Property -> Bool)
-> (ExtensionsV3Property -> ExtensionsV3Property -> Bool)
-> Eq ExtensionsV3Property
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: ExtensionsV3Property -> ExtensionsV3Property -> Bool
== :: ExtensionsV3Property -> ExtensionsV3Property -> Bool
$c/= :: ExtensionsV3Property -> ExtensionsV3Property -> Bool
/= :: ExtensionsV3Property -> ExtensionsV3Property -> Bool
Prelude.Eq, Int -> ExtensionsV3Property -> ShowS
[ExtensionsV3Property] -> ShowS
ExtensionsV3Property -> String
(Int -> ExtensionsV3Property -> ShowS)
-> (ExtensionsV3Property -> String)
-> ([ExtensionsV3Property] -> ShowS)
-> Show ExtensionsV3Property
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> ExtensionsV3Property -> ShowS
showsPrec :: Int -> ExtensionsV3Property -> ShowS
$cshow :: ExtensionsV3Property -> String
show :: ExtensionsV3Property -> String
$cshowList :: [ExtensionsV3Property] -> ShowS
showList :: [ExtensionsV3Property] -> ShowS
Prelude.Show)
mkExtensionsV3Property :: KeyUsageProperty -> ExtensionsV3Property
mkExtensionsV3Property :: KeyUsageProperty -> ExtensionsV3Property
mkExtensionsV3Property KeyUsageProperty
keyUsage
  = ExtensionsV3Property
      {haddock_workaround_ :: ()
haddock_workaround_ = (), keyUsage :: KeyUsageProperty
keyUsage = KeyUsageProperty
keyUsage,
       applicationPolicies :: Maybe ApplicationPoliciesProperty
applicationPolicies = Maybe ApplicationPoliciesProperty
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties ExtensionsV3Property where
  toResourceProperties :: ExtensionsV3Property -> ResourceProperties
toResourceProperties ExtensionsV3Property {Maybe ApplicationPoliciesProperty
()
KeyUsageProperty
haddock_workaround_ :: ExtensionsV3Property -> ()
applicationPolicies :: ExtensionsV3Property -> Maybe ApplicationPoliciesProperty
keyUsage :: ExtensionsV3Property -> KeyUsageProperty
haddock_workaround_ :: ()
applicationPolicies :: Maybe ApplicationPoliciesProperty
keyUsage :: KeyUsageProperty
..}
    = ResourceProperties
        {awsType :: Text
awsType = Text
"AWS::PCAConnectorAD::Template.ExtensionsV3",
         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 ExtensionsV3Property where
  toJSON :: ExtensionsV3Property -> Value
toJSON ExtensionsV3Property {Maybe ApplicationPoliciesProperty
()
KeyUsageProperty
haddock_workaround_ :: ExtensionsV3Property -> ()
applicationPolicies :: ExtensionsV3Property -> Maybe ApplicationPoliciesProperty
keyUsage :: ExtensionsV3Property -> 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" ExtensionsV3Property where
  type PropertyType "ApplicationPolicies" ExtensionsV3Property = ApplicationPoliciesProperty
  set :: PropertyType "ApplicationPolicies" ExtensionsV3Property
-> ExtensionsV3Property -> ExtensionsV3Property
set PropertyType "ApplicationPolicies" ExtensionsV3Property
newValue ExtensionsV3Property {Maybe ApplicationPoliciesProperty
()
KeyUsageProperty
haddock_workaround_ :: ExtensionsV3Property -> ()
applicationPolicies :: ExtensionsV3Property -> Maybe ApplicationPoliciesProperty
keyUsage :: ExtensionsV3Property -> KeyUsageProperty
haddock_workaround_ :: ()
applicationPolicies :: Maybe ApplicationPoliciesProperty
keyUsage :: KeyUsageProperty
..}
    = ExtensionsV3Property
        {applicationPolicies :: Maybe ApplicationPoliciesProperty
applicationPolicies = ApplicationPoliciesProperty -> Maybe ApplicationPoliciesProperty
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "ApplicationPolicies" ExtensionsV3Property
ApplicationPoliciesProperty
newValue, ()
KeyUsageProperty
haddock_workaround_ :: ()
keyUsage :: KeyUsageProperty
haddock_workaround_ :: ()
keyUsage :: KeyUsageProperty
..}
instance Property "KeyUsage" ExtensionsV3Property where
  type PropertyType "KeyUsage" ExtensionsV3Property = KeyUsageProperty
  set :: PropertyType "KeyUsage" ExtensionsV3Property
-> ExtensionsV3Property -> ExtensionsV3Property
set PropertyType "KeyUsage" ExtensionsV3Property
newValue ExtensionsV3Property {Maybe ApplicationPoliciesProperty
()
KeyUsageProperty
haddock_workaround_ :: ExtensionsV3Property -> ()
applicationPolicies :: ExtensionsV3Property -> Maybe ApplicationPoliciesProperty
keyUsage :: ExtensionsV3Property -> KeyUsageProperty
haddock_workaround_ :: ()
applicationPolicies :: Maybe ApplicationPoliciesProperty
keyUsage :: KeyUsageProperty
..}
    = ExtensionsV3Property {keyUsage :: KeyUsageProperty
keyUsage = PropertyType "KeyUsage" ExtensionsV3Property
KeyUsageProperty
newValue, Maybe ApplicationPoliciesProperty
()
haddock_workaround_ :: ()
applicationPolicies :: Maybe ApplicationPoliciesProperty
haddock_workaround_ :: ()
applicationPolicies :: Maybe ApplicationPoliciesProperty
..}