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