module Stratosphere.EC2.ClientVpnEndpoint.ConnectionLogOptionsProperty (
ConnectionLogOptionsProperty(..), mkConnectionLogOptionsProperty
) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import Stratosphere.ResourceProperties
import Stratosphere.Value
data ConnectionLogOptionsProperty
=
ConnectionLogOptionsProperty {ConnectionLogOptionsProperty -> ()
haddock_workaround_ :: (),
ConnectionLogOptionsProperty -> Maybe (Value Text)
cloudwatchLogGroup :: (Prelude.Maybe (Value Prelude.Text)),
ConnectionLogOptionsProperty -> Maybe (Value Text)
cloudwatchLogStream :: (Prelude.Maybe (Value Prelude.Text)),
ConnectionLogOptionsProperty -> Value Bool
enabled :: (Value Prelude.Bool)}
deriving stock (ConnectionLogOptionsProperty
-> ConnectionLogOptionsProperty -> Bool
(ConnectionLogOptionsProperty
-> ConnectionLogOptionsProperty -> Bool)
-> (ConnectionLogOptionsProperty
-> ConnectionLogOptionsProperty -> Bool)
-> Eq ConnectionLogOptionsProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: ConnectionLogOptionsProperty
-> ConnectionLogOptionsProperty -> Bool
== :: ConnectionLogOptionsProperty
-> ConnectionLogOptionsProperty -> Bool
$c/= :: ConnectionLogOptionsProperty
-> ConnectionLogOptionsProperty -> Bool
/= :: ConnectionLogOptionsProperty
-> ConnectionLogOptionsProperty -> Bool
Prelude.Eq, Int -> ConnectionLogOptionsProperty -> ShowS
[ConnectionLogOptionsProperty] -> ShowS
ConnectionLogOptionsProperty -> String
(Int -> ConnectionLogOptionsProperty -> ShowS)
-> (ConnectionLogOptionsProperty -> String)
-> ([ConnectionLogOptionsProperty] -> ShowS)
-> Show ConnectionLogOptionsProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> ConnectionLogOptionsProperty -> ShowS
showsPrec :: Int -> ConnectionLogOptionsProperty -> ShowS
$cshow :: ConnectionLogOptionsProperty -> String
show :: ConnectionLogOptionsProperty -> String
$cshowList :: [ConnectionLogOptionsProperty] -> ShowS
showList :: [ConnectionLogOptionsProperty] -> ShowS
Prelude.Show)
mkConnectionLogOptionsProperty ::
Value Prelude.Bool -> ConnectionLogOptionsProperty
mkConnectionLogOptionsProperty :: Value Bool -> ConnectionLogOptionsProperty
mkConnectionLogOptionsProperty Value Bool
enabled
= ConnectionLogOptionsProperty
{haddock_workaround_ :: ()
haddock_workaround_ = (), enabled :: Value Bool
enabled = Value Bool
enabled,
cloudwatchLogGroup :: Maybe (Value Text)
cloudwatchLogGroup = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing,
cloudwatchLogStream :: Maybe (Value Text)
cloudwatchLogStream = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties ConnectionLogOptionsProperty where
toResourceProperties :: ConnectionLogOptionsProperty -> ResourceProperties
toResourceProperties ConnectionLogOptionsProperty {Maybe (Value Text)
()
Value Bool
haddock_workaround_ :: ConnectionLogOptionsProperty -> ()
cloudwatchLogGroup :: ConnectionLogOptionsProperty -> Maybe (Value Text)
cloudwatchLogStream :: ConnectionLogOptionsProperty -> Maybe (Value Text)
enabled :: ConnectionLogOptionsProperty -> Value Bool
haddock_workaround_ :: ()
cloudwatchLogGroup :: Maybe (Value Text)
cloudwatchLogStream :: Maybe (Value Text)
enabled :: Value Bool
..}
= ResourceProperties
{awsType :: Text
awsType = Text
"AWS::EC2::ClientVpnEndpoint.ConnectionLogOptions",
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
"Enabled" 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
enabled]
([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
"CloudwatchLogGroup" (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)
cloudwatchLogGroup,
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
"CloudwatchLogStream" (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)
cloudwatchLogStream]))}
instance JSON.ToJSON ConnectionLogOptionsProperty where
toJSON :: ConnectionLogOptionsProperty -> Value
toJSON ConnectionLogOptionsProperty {Maybe (Value Text)
()
Value Bool
haddock_workaround_ :: ConnectionLogOptionsProperty -> ()
cloudwatchLogGroup :: ConnectionLogOptionsProperty -> Maybe (Value Text)
cloudwatchLogStream :: ConnectionLogOptionsProperty -> Maybe (Value Text)
enabled :: ConnectionLogOptionsProperty -> Value Bool
haddock_workaround_ :: ()
cloudwatchLogGroup :: Maybe (Value Text)
cloudwatchLogStream :: Maybe (Value Text)
enabled :: Value Bool
..}
= [(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
"Enabled" 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
enabled]
([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
"CloudwatchLogGroup" (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)
cloudwatchLogGroup,
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
"CloudwatchLogStream" (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)
cloudwatchLogStream])))
instance Property "CloudwatchLogGroup" ConnectionLogOptionsProperty where
type PropertyType "CloudwatchLogGroup" ConnectionLogOptionsProperty = Value Prelude.Text
set :: PropertyType "CloudwatchLogGroup" ConnectionLogOptionsProperty
-> ConnectionLogOptionsProperty -> ConnectionLogOptionsProperty
set PropertyType "CloudwatchLogGroup" ConnectionLogOptionsProperty
newValue ConnectionLogOptionsProperty {Maybe (Value Text)
()
Value Bool
haddock_workaround_ :: ConnectionLogOptionsProperty -> ()
cloudwatchLogGroup :: ConnectionLogOptionsProperty -> Maybe (Value Text)
cloudwatchLogStream :: ConnectionLogOptionsProperty -> Maybe (Value Text)
enabled :: ConnectionLogOptionsProperty -> Value Bool
haddock_workaround_ :: ()
cloudwatchLogGroup :: Maybe (Value Text)
cloudwatchLogStream :: Maybe (Value Text)
enabled :: Value Bool
..}
= ConnectionLogOptionsProperty
{cloudwatchLogGroup :: Maybe (Value Text)
cloudwatchLogGroup = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "CloudwatchLogGroup" ConnectionLogOptionsProperty
Value Text
newValue, Maybe (Value Text)
()
Value Bool
haddock_workaround_ :: ()
cloudwatchLogStream :: Maybe (Value Text)
enabled :: Value Bool
haddock_workaround_ :: ()
cloudwatchLogStream :: Maybe (Value Text)
enabled :: Value Bool
..}
instance Property "CloudwatchLogStream" ConnectionLogOptionsProperty where
type PropertyType "CloudwatchLogStream" ConnectionLogOptionsProperty = Value Prelude.Text
set :: PropertyType "CloudwatchLogStream" ConnectionLogOptionsProperty
-> ConnectionLogOptionsProperty -> ConnectionLogOptionsProperty
set PropertyType "CloudwatchLogStream" ConnectionLogOptionsProperty
newValue ConnectionLogOptionsProperty {Maybe (Value Text)
()
Value Bool
haddock_workaround_ :: ConnectionLogOptionsProperty -> ()
cloudwatchLogGroup :: ConnectionLogOptionsProperty -> Maybe (Value Text)
cloudwatchLogStream :: ConnectionLogOptionsProperty -> Maybe (Value Text)
enabled :: ConnectionLogOptionsProperty -> Value Bool
haddock_workaround_ :: ()
cloudwatchLogGroup :: Maybe (Value Text)
cloudwatchLogStream :: Maybe (Value Text)
enabled :: Value Bool
..}
= ConnectionLogOptionsProperty
{cloudwatchLogStream :: Maybe (Value Text)
cloudwatchLogStream = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "CloudwatchLogStream" ConnectionLogOptionsProperty
Value Text
newValue, Maybe (Value Text)
()
Value Bool
haddock_workaround_ :: ()
cloudwatchLogGroup :: Maybe (Value Text)
enabled :: Value Bool
haddock_workaround_ :: ()
cloudwatchLogGroup :: Maybe (Value Text)
enabled :: Value Bool
..}
instance Property "Enabled" ConnectionLogOptionsProperty where
type PropertyType "Enabled" ConnectionLogOptionsProperty = Value Prelude.Bool
set :: PropertyType "Enabled" ConnectionLogOptionsProperty
-> ConnectionLogOptionsProperty -> ConnectionLogOptionsProperty
set PropertyType "Enabled" ConnectionLogOptionsProperty
newValue ConnectionLogOptionsProperty {Maybe (Value Text)
()
Value Bool
haddock_workaround_ :: ConnectionLogOptionsProperty -> ()
cloudwatchLogGroup :: ConnectionLogOptionsProperty -> Maybe (Value Text)
cloudwatchLogStream :: ConnectionLogOptionsProperty -> Maybe (Value Text)
enabled :: ConnectionLogOptionsProperty -> Value Bool
haddock_workaround_ :: ()
cloudwatchLogGroup :: Maybe (Value Text)
cloudwatchLogStream :: Maybe (Value Text)
enabled :: Value Bool
..}
= ConnectionLogOptionsProperty {enabled :: Value Bool
enabled = PropertyType "Enabled" ConnectionLogOptionsProperty
Value Bool
newValue, Maybe (Value Text)
()
haddock_workaround_ :: ()
cloudwatchLogGroup :: Maybe (Value Text)
cloudwatchLogStream :: Maybe (Value Text)
haddock_workaround_ :: ()
cloudwatchLogGroup :: Maybe (Value Text)
cloudwatchLogStream :: Maybe (Value Text)
..}