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