module Stratosphere.BCMDataExports.Export (
module Exports, Export(..), mkExport
) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import {-# SOURCE #-} Stratosphere.BCMDataExports.Export.ExportProperty as Exports
import {-# SOURCE #-} Stratosphere.BCMDataExports.Export.ResourceTagProperty as Exports
import Stratosphere.ResourceProperties
data Export
=
Export {Export -> ()
haddock_workaround_ :: (),
Export -> ExportProperty
export :: ExportProperty,
Export -> Maybe [ResourceTagProperty]
tags :: (Prelude.Maybe [ResourceTagProperty])}
deriving stock (Export -> Export -> Bool
(Export -> Export -> Bool)
-> (Export -> Export -> Bool) -> Eq Export
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: Export -> Export -> Bool
== :: Export -> Export -> Bool
$c/= :: Export -> Export -> Bool
/= :: Export -> Export -> Bool
Prelude.Eq, Int -> Export -> ShowS
[Export] -> ShowS
Export -> String
(Int -> Export -> ShowS)
-> (Export -> String) -> ([Export] -> ShowS) -> Show Export
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> Export -> ShowS
showsPrec :: Int -> Export -> ShowS
$cshow :: Export -> String
show :: Export -> String
$cshowList :: [Export] -> ShowS
showList :: [Export] -> ShowS
Prelude.Show)
mkExport :: ExportProperty -> Export
mkExport :: ExportProperty -> Export
mkExport ExportProperty
export
= Export
{haddock_workaround_ :: ()
haddock_workaround_ = (), export :: ExportProperty
export = ExportProperty
export, tags :: Maybe [ResourceTagProperty]
tags = Maybe [ResourceTagProperty]
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties Export where
toResourceProperties :: Export -> ResourceProperties
toResourceProperties Export {Maybe [ResourceTagProperty]
()
ExportProperty
haddock_workaround_ :: Export -> ()
export :: Export -> ExportProperty
tags :: Export -> Maybe [ResourceTagProperty]
haddock_workaround_ :: ()
export :: ExportProperty
tags :: Maybe [ResourceTagProperty]
..}
= ResourceProperties
{awsType :: Text
awsType = Text
"AWS::BCMDataExports::Export",
supportsTags :: Bool
supportsTags = Bool
Prelude.True,
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
"Export" Key -> ExportProperty -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= ExportProperty
export]
([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes [Key -> [ResourceTagProperty] -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"Tags" ([ResourceTagProperty] -> (Key, Value))
-> Maybe [ResourceTagProperty] -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [ResourceTagProperty]
tags]))}
instance JSON.ToJSON Export where
toJSON :: Export -> Value
toJSON Export {Maybe [ResourceTagProperty]
()
ExportProperty
haddock_workaround_ :: Export -> ()
export :: Export -> ExportProperty
tags :: Export -> Maybe [ResourceTagProperty]
haddock_workaround_ :: ()
export :: ExportProperty
tags :: Maybe [ResourceTagProperty]
..}
= [(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
"Export" Key -> ExportProperty -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= ExportProperty
export]
([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes [Key -> [ResourceTagProperty] -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"Tags" ([ResourceTagProperty] -> (Key, Value))
-> Maybe [ResourceTagProperty] -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [ResourceTagProperty]
tags])))
instance Property "Export" Export where
type PropertyType "Export" Export = ExportProperty
set :: PropertyType "Export" Export -> Export -> Export
set PropertyType "Export" Export
newValue Export {Maybe [ResourceTagProperty]
()
ExportProperty
haddock_workaround_ :: Export -> ()
export :: Export -> ExportProperty
tags :: Export -> Maybe [ResourceTagProperty]
haddock_workaround_ :: ()
export :: ExportProperty
tags :: Maybe [ResourceTagProperty]
..} = Export {export :: ExportProperty
export = PropertyType "Export" Export
ExportProperty
newValue, Maybe [ResourceTagProperty]
()
haddock_workaround_ :: ()
tags :: Maybe [ResourceTagProperty]
haddock_workaround_ :: ()
tags :: Maybe [ResourceTagProperty]
..}
instance Property "Tags" Export where
type PropertyType "Tags" Export = [ResourceTagProperty]
set :: PropertyType "Tags" Export -> Export -> Export
set PropertyType "Tags" Export
newValue Export {Maybe [ResourceTagProperty]
()
ExportProperty
haddock_workaround_ :: Export -> ()
export :: Export -> ExportProperty
tags :: Export -> Maybe [ResourceTagProperty]
haddock_workaround_ :: ()
export :: ExportProperty
tags :: Maybe [ResourceTagProperty]
..}
= Export {tags :: Maybe [ResourceTagProperty]
tags = [ResourceTagProperty] -> Maybe [ResourceTagProperty]
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure [ResourceTagProperty]
PropertyType "Tags" Export
newValue, ()
ExportProperty
haddock_workaround_ :: ()
export :: ExportProperty
haddock_workaround_ :: ()
export :: ExportProperty
..}