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