module Stratosphere.Logs.Transformer.ListToMapProperty (
ListToMapProperty(..), mkListToMapProperty
) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import Stratosphere.ResourceProperties
import Stratosphere.Value
data ListToMapProperty
=
ListToMapProperty {ListToMapProperty -> ()
haddock_workaround_ :: (),
ListToMapProperty -> Maybe (Value Bool)
flatten :: (Prelude.Maybe (Value Prelude.Bool)),
ListToMapProperty -> Maybe (Value Text)
flattenedElement :: (Prelude.Maybe (Value Prelude.Text)),
ListToMapProperty -> Value Text
key :: (Value Prelude.Text),
ListToMapProperty -> Value Text
source :: (Value Prelude.Text),
ListToMapProperty -> Maybe (Value Text)
target :: (Prelude.Maybe (Value Prelude.Text)),
ListToMapProperty -> Maybe (Value Text)
valueKey :: (Prelude.Maybe (Value Prelude.Text))}
deriving stock (ListToMapProperty -> ListToMapProperty -> Bool
(ListToMapProperty -> ListToMapProperty -> Bool)
-> (ListToMapProperty -> ListToMapProperty -> Bool)
-> Eq ListToMapProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: ListToMapProperty -> ListToMapProperty -> Bool
== :: ListToMapProperty -> ListToMapProperty -> Bool
$c/= :: ListToMapProperty -> ListToMapProperty -> Bool
/= :: ListToMapProperty -> ListToMapProperty -> Bool
Prelude.Eq, Int -> ListToMapProperty -> ShowS
[ListToMapProperty] -> ShowS
ListToMapProperty -> String
(Int -> ListToMapProperty -> ShowS)
-> (ListToMapProperty -> String)
-> ([ListToMapProperty] -> ShowS)
-> Show ListToMapProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> ListToMapProperty -> ShowS
showsPrec :: Int -> ListToMapProperty -> ShowS
$cshow :: ListToMapProperty -> String
show :: ListToMapProperty -> String
$cshowList :: [ListToMapProperty] -> ShowS
showList :: [ListToMapProperty] -> ShowS
Prelude.Show)
mkListToMapProperty ::
Value Prelude.Text -> Value Prelude.Text -> ListToMapProperty
mkListToMapProperty :: Value Text -> Value Text -> ListToMapProperty
mkListToMapProperty Value Text
key Value Text
source
= ListToMapProperty
{haddock_workaround_ :: ()
haddock_workaround_ = (), key :: Value Text
key = Value Text
key, source :: Value Text
source = Value Text
source,
flatten :: Maybe (Value Bool)
flatten = Maybe (Value Bool)
forall a. Maybe a
Prelude.Nothing, flattenedElement :: Maybe (Value Text)
flattenedElement = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing,
target :: Maybe (Value Text)
target = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing, valueKey :: Maybe (Value Text)
valueKey = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties ListToMapProperty where
toResourceProperties :: ListToMapProperty -> ResourceProperties
toResourceProperties ListToMapProperty {Maybe (Value Bool)
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ListToMapProperty -> ()
flatten :: ListToMapProperty -> Maybe (Value Bool)
flattenedElement :: ListToMapProperty -> Maybe (Value Text)
key :: ListToMapProperty -> Value Text
source :: ListToMapProperty -> Value Text
target :: ListToMapProperty -> Maybe (Value Text)
valueKey :: ListToMapProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
flatten :: Maybe (Value Bool)
flattenedElement :: Maybe (Value Text)
key :: Value Text
source :: Value Text
target :: Maybe (Value Text)
valueKey :: Maybe (Value Text)
..}
= ResourceProperties
{awsType :: Text
awsType = Text
"AWS::Logs::Transformer.ListToMap",
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
"Key" 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..= Value Text
key, Key
"Source" 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..= Value Text
source]
([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[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..=) Key
"Flatten" (Value Bool -> (Key, Value))
-> Maybe (Value Bool) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Bool)
flatten,
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
"FlattenedElement" (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)
flattenedElement,
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
"Target" (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)
target,
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
"ValueKey" (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)
valueKey]))}
instance JSON.ToJSON ListToMapProperty where
toJSON :: ListToMapProperty -> Value
toJSON ListToMapProperty {Maybe (Value Bool)
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ListToMapProperty -> ()
flatten :: ListToMapProperty -> Maybe (Value Bool)
flattenedElement :: ListToMapProperty -> Maybe (Value Text)
key :: ListToMapProperty -> Value Text
source :: ListToMapProperty -> Value Text
target :: ListToMapProperty -> Maybe (Value Text)
valueKey :: ListToMapProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
flatten :: Maybe (Value Bool)
flattenedElement :: Maybe (Value Text)
key :: Value Text
source :: Value Text
target :: Maybe (Value Text)
valueKey :: 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
"Key" 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..= Value Text
key, Key
"Source" 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..= Value Text
source]
([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[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..=) Key
"Flatten" (Value Bool -> (Key, Value))
-> Maybe (Value Bool) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Bool)
flatten,
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
"FlattenedElement" (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)
flattenedElement,
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
"Target" (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)
target,
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
"ValueKey" (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)
valueKey])))
instance Property "Flatten" ListToMapProperty where
type PropertyType "Flatten" ListToMapProperty = Value Prelude.Bool
set :: PropertyType "Flatten" ListToMapProperty
-> ListToMapProperty -> ListToMapProperty
set PropertyType "Flatten" ListToMapProperty
newValue ListToMapProperty {Maybe (Value Bool)
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ListToMapProperty -> ()
flatten :: ListToMapProperty -> Maybe (Value Bool)
flattenedElement :: ListToMapProperty -> Maybe (Value Text)
key :: ListToMapProperty -> Value Text
source :: ListToMapProperty -> Value Text
target :: ListToMapProperty -> Maybe (Value Text)
valueKey :: ListToMapProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
flatten :: Maybe (Value Bool)
flattenedElement :: Maybe (Value Text)
key :: Value Text
source :: Value Text
target :: Maybe (Value Text)
valueKey :: Maybe (Value Text)
..}
= ListToMapProperty {flatten :: Maybe (Value Bool)
flatten = Value Bool -> Maybe (Value Bool)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "Flatten" ListToMapProperty
Value Bool
newValue, Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ()
flattenedElement :: Maybe (Value Text)
key :: Value Text
source :: Value Text
target :: Maybe (Value Text)
valueKey :: Maybe (Value Text)
haddock_workaround_ :: ()
flattenedElement :: Maybe (Value Text)
key :: Value Text
source :: Value Text
target :: Maybe (Value Text)
valueKey :: Maybe (Value Text)
..}
instance Property "FlattenedElement" ListToMapProperty where
type PropertyType "FlattenedElement" ListToMapProperty = Value Prelude.Text
set :: PropertyType "FlattenedElement" ListToMapProperty
-> ListToMapProperty -> ListToMapProperty
set PropertyType "FlattenedElement" ListToMapProperty
newValue ListToMapProperty {Maybe (Value Bool)
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ListToMapProperty -> ()
flatten :: ListToMapProperty -> Maybe (Value Bool)
flattenedElement :: ListToMapProperty -> Maybe (Value Text)
key :: ListToMapProperty -> Value Text
source :: ListToMapProperty -> Value Text
target :: ListToMapProperty -> Maybe (Value Text)
valueKey :: ListToMapProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
flatten :: Maybe (Value Bool)
flattenedElement :: Maybe (Value Text)
key :: Value Text
source :: Value Text
target :: Maybe (Value Text)
valueKey :: Maybe (Value Text)
..}
= ListToMapProperty {flattenedElement :: Maybe (Value Text)
flattenedElement = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "FlattenedElement" ListToMapProperty
Value Text
newValue, Maybe (Value Bool)
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ()
flatten :: Maybe (Value Bool)
key :: Value Text
source :: Value Text
target :: Maybe (Value Text)
valueKey :: Maybe (Value Text)
haddock_workaround_ :: ()
flatten :: Maybe (Value Bool)
key :: Value Text
source :: Value Text
target :: Maybe (Value Text)
valueKey :: Maybe (Value Text)
..}
instance Property "Key" ListToMapProperty where
type PropertyType "Key" ListToMapProperty = Value Prelude.Text
set :: PropertyType "Key" ListToMapProperty
-> ListToMapProperty -> ListToMapProperty
set PropertyType "Key" ListToMapProperty
newValue ListToMapProperty {Maybe (Value Bool)
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ListToMapProperty -> ()
flatten :: ListToMapProperty -> Maybe (Value Bool)
flattenedElement :: ListToMapProperty -> Maybe (Value Text)
key :: ListToMapProperty -> Value Text
source :: ListToMapProperty -> Value Text
target :: ListToMapProperty -> Maybe (Value Text)
valueKey :: ListToMapProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
flatten :: Maybe (Value Bool)
flattenedElement :: Maybe (Value Text)
key :: Value Text
source :: Value Text
target :: Maybe (Value Text)
valueKey :: Maybe (Value Text)
..}
= ListToMapProperty {key :: Value Text
key = PropertyType "Key" ListToMapProperty
Value Text
newValue, Maybe (Value Bool)
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ()
flatten :: Maybe (Value Bool)
flattenedElement :: Maybe (Value Text)
source :: Value Text
target :: Maybe (Value Text)
valueKey :: Maybe (Value Text)
haddock_workaround_ :: ()
flatten :: Maybe (Value Bool)
flattenedElement :: Maybe (Value Text)
source :: Value Text
target :: Maybe (Value Text)
valueKey :: Maybe (Value Text)
..}
instance Property "Source" ListToMapProperty where
type PropertyType "Source" ListToMapProperty = Value Prelude.Text
set :: PropertyType "Source" ListToMapProperty
-> ListToMapProperty -> ListToMapProperty
set PropertyType "Source" ListToMapProperty
newValue ListToMapProperty {Maybe (Value Bool)
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ListToMapProperty -> ()
flatten :: ListToMapProperty -> Maybe (Value Bool)
flattenedElement :: ListToMapProperty -> Maybe (Value Text)
key :: ListToMapProperty -> Value Text
source :: ListToMapProperty -> Value Text
target :: ListToMapProperty -> Maybe (Value Text)
valueKey :: ListToMapProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
flatten :: Maybe (Value Bool)
flattenedElement :: Maybe (Value Text)
key :: Value Text
source :: Value Text
target :: Maybe (Value Text)
valueKey :: Maybe (Value Text)
..}
= ListToMapProperty {source :: Value Text
source = PropertyType "Source" ListToMapProperty
Value Text
newValue, Maybe (Value Bool)
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ()
flatten :: Maybe (Value Bool)
flattenedElement :: Maybe (Value Text)
key :: Value Text
target :: Maybe (Value Text)
valueKey :: Maybe (Value Text)
haddock_workaround_ :: ()
flatten :: Maybe (Value Bool)
flattenedElement :: Maybe (Value Text)
key :: Value Text
target :: Maybe (Value Text)
valueKey :: Maybe (Value Text)
..}
instance Property "Target" ListToMapProperty where
type PropertyType "Target" ListToMapProperty = Value Prelude.Text
set :: PropertyType "Target" ListToMapProperty
-> ListToMapProperty -> ListToMapProperty
set PropertyType "Target" ListToMapProperty
newValue ListToMapProperty {Maybe (Value Bool)
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ListToMapProperty -> ()
flatten :: ListToMapProperty -> Maybe (Value Bool)
flattenedElement :: ListToMapProperty -> Maybe (Value Text)
key :: ListToMapProperty -> Value Text
source :: ListToMapProperty -> Value Text
target :: ListToMapProperty -> Maybe (Value Text)
valueKey :: ListToMapProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
flatten :: Maybe (Value Bool)
flattenedElement :: Maybe (Value Text)
key :: Value Text
source :: Value Text
target :: Maybe (Value Text)
valueKey :: Maybe (Value Text)
..}
= ListToMapProperty {target :: Maybe (Value Text)
target = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "Target" ListToMapProperty
Value Text
newValue, Maybe (Value Bool)
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ()
flatten :: Maybe (Value Bool)
flattenedElement :: Maybe (Value Text)
key :: Value Text
source :: Value Text
valueKey :: Maybe (Value Text)
haddock_workaround_ :: ()
flatten :: Maybe (Value Bool)
flattenedElement :: Maybe (Value Text)
key :: Value Text
source :: Value Text
valueKey :: Maybe (Value Text)
..}
instance Property "ValueKey" ListToMapProperty where
type PropertyType "ValueKey" ListToMapProperty = Value Prelude.Text
set :: PropertyType "ValueKey" ListToMapProperty
-> ListToMapProperty -> ListToMapProperty
set PropertyType "ValueKey" ListToMapProperty
newValue ListToMapProperty {Maybe (Value Bool)
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ListToMapProperty -> ()
flatten :: ListToMapProperty -> Maybe (Value Bool)
flattenedElement :: ListToMapProperty -> Maybe (Value Text)
key :: ListToMapProperty -> Value Text
source :: ListToMapProperty -> Value Text
target :: ListToMapProperty -> Maybe (Value Text)
valueKey :: ListToMapProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
flatten :: Maybe (Value Bool)
flattenedElement :: Maybe (Value Text)
key :: Value Text
source :: Value Text
target :: Maybe (Value Text)
valueKey :: Maybe (Value Text)
..}
= ListToMapProperty {valueKey :: Maybe (Value Text)
valueKey = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "ValueKey" ListToMapProperty
Value Text
newValue, Maybe (Value Bool)
Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ()
flatten :: Maybe (Value Bool)
flattenedElement :: Maybe (Value Text)
key :: Value Text
source :: Value Text
target :: Maybe (Value Text)
haddock_workaround_ :: ()
flatten :: Maybe (Value Bool)
flattenedElement :: Maybe (Value Text)
key :: Value Text
source :: Value Text
target :: Maybe (Value Text)
..}