module Stratosphere.IoTAnalytics.Datastore.FileFormatConfigurationProperty (
module Exports, FileFormatConfigurationProperty(..),
mkFileFormatConfigurationProperty
) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import {-# SOURCE #-} Stratosphere.IoTAnalytics.Datastore.ParquetConfigurationProperty as Exports
import Stratosphere.ResourceProperties
data FileFormatConfigurationProperty
=
FileFormatConfigurationProperty {FileFormatConfigurationProperty -> ()
haddock_workaround_ :: (),
FileFormatConfigurationProperty -> Maybe Object
jsonConfiguration :: (Prelude.Maybe JSON.Object),
FileFormatConfigurationProperty
-> Maybe ParquetConfigurationProperty
parquetConfiguration :: (Prelude.Maybe ParquetConfigurationProperty)}
deriving stock (FileFormatConfigurationProperty
-> FileFormatConfigurationProperty -> Bool
(FileFormatConfigurationProperty
-> FileFormatConfigurationProperty -> Bool)
-> (FileFormatConfigurationProperty
-> FileFormatConfigurationProperty -> Bool)
-> Eq FileFormatConfigurationProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: FileFormatConfigurationProperty
-> FileFormatConfigurationProperty -> Bool
== :: FileFormatConfigurationProperty
-> FileFormatConfigurationProperty -> Bool
$c/= :: FileFormatConfigurationProperty
-> FileFormatConfigurationProperty -> Bool
/= :: FileFormatConfigurationProperty
-> FileFormatConfigurationProperty -> Bool
Prelude.Eq, Int -> FileFormatConfigurationProperty -> ShowS
[FileFormatConfigurationProperty] -> ShowS
FileFormatConfigurationProperty -> String
(Int -> FileFormatConfigurationProperty -> ShowS)
-> (FileFormatConfigurationProperty -> String)
-> ([FileFormatConfigurationProperty] -> ShowS)
-> Show FileFormatConfigurationProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> FileFormatConfigurationProperty -> ShowS
showsPrec :: Int -> FileFormatConfigurationProperty -> ShowS
$cshow :: FileFormatConfigurationProperty -> String
show :: FileFormatConfigurationProperty -> String
$cshowList :: [FileFormatConfigurationProperty] -> ShowS
showList :: [FileFormatConfigurationProperty] -> ShowS
Prelude.Show)
mkFileFormatConfigurationProperty ::
FileFormatConfigurationProperty
mkFileFormatConfigurationProperty :: FileFormatConfigurationProperty
mkFileFormatConfigurationProperty
= FileFormatConfigurationProperty
{haddock_workaround_ :: ()
haddock_workaround_ = (), jsonConfiguration :: Maybe Object
jsonConfiguration = Maybe Object
forall a. Maybe a
Prelude.Nothing,
parquetConfiguration :: Maybe ParquetConfigurationProperty
parquetConfiguration = Maybe ParquetConfigurationProperty
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties FileFormatConfigurationProperty where
toResourceProperties :: FileFormatConfigurationProperty -> ResourceProperties
toResourceProperties FileFormatConfigurationProperty {Maybe Object
Maybe ParquetConfigurationProperty
()
haddock_workaround_ :: FileFormatConfigurationProperty -> ()
jsonConfiguration :: FileFormatConfigurationProperty -> Maybe Object
parquetConfiguration :: FileFormatConfigurationProperty
-> Maybe ParquetConfigurationProperty
haddock_workaround_ :: ()
jsonConfiguration :: Maybe Object
parquetConfiguration :: Maybe ParquetConfigurationProperty
..}
= ResourceProperties
{awsType :: Text
awsType = Text
"AWS::IoTAnalytics::Datastore.FileFormatConfiguration",
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 -> Object -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"JsonConfiguration" (Object -> (Key, Value)) -> Maybe Object -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Object
jsonConfiguration,
Key -> ParquetConfigurationProperty -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"ParquetConfiguration"
(ParquetConfigurationProperty -> (Key, Value))
-> Maybe ParquetConfigurationProperty -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe ParquetConfigurationProperty
parquetConfiguration])}
instance JSON.ToJSON FileFormatConfigurationProperty where
toJSON :: FileFormatConfigurationProperty -> Value
toJSON FileFormatConfigurationProperty {Maybe Object
Maybe ParquetConfigurationProperty
()
haddock_workaround_ :: FileFormatConfigurationProperty -> ()
jsonConfiguration :: FileFormatConfigurationProperty -> Maybe Object
parquetConfiguration :: FileFormatConfigurationProperty
-> Maybe ParquetConfigurationProperty
haddock_workaround_ :: ()
jsonConfiguration :: Maybe Object
parquetConfiguration :: Maybe ParquetConfigurationProperty
..}
= [(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 -> Object -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"JsonConfiguration" (Object -> (Key, Value)) -> Maybe Object -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Object
jsonConfiguration,
Key -> ParquetConfigurationProperty -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"ParquetConfiguration"
(ParquetConfigurationProperty -> (Key, Value))
-> Maybe ParquetConfigurationProperty -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe ParquetConfigurationProperty
parquetConfiguration]))
instance Property "JsonConfiguration" FileFormatConfigurationProperty where
type PropertyType "JsonConfiguration" FileFormatConfigurationProperty = JSON.Object
set :: PropertyType "JsonConfiguration" FileFormatConfigurationProperty
-> FileFormatConfigurationProperty
-> FileFormatConfigurationProperty
set PropertyType "JsonConfiguration" FileFormatConfigurationProperty
newValue FileFormatConfigurationProperty {Maybe Object
Maybe ParquetConfigurationProperty
()
haddock_workaround_ :: FileFormatConfigurationProperty -> ()
jsonConfiguration :: FileFormatConfigurationProperty -> Maybe Object
parquetConfiguration :: FileFormatConfigurationProperty
-> Maybe ParquetConfigurationProperty
haddock_workaround_ :: ()
jsonConfiguration :: Maybe Object
parquetConfiguration :: Maybe ParquetConfigurationProperty
..}
= FileFormatConfigurationProperty
{jsonConfiguration :: Maybe Object
jsonConfiguration = Object -> Maybe Object
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure Object
PropertyType "JsonConfiguration" FileFormatConfigurationProperty
newValue, Maybe ParquetConfigurationProperty
()
haddock_workaround_ :: ()
parquetConfiguration :: Maybe ParquetConfigurationProperty
haddock_workaround_ :: ()
parquetConfiguration :: Maybe ParquetConfigurationProperty
..}
instance Property "ParquetConfiguration" FileFormatConfigurationProperty where
type PropertyType "ParquetConfiguration" FileFormatConfigurationProperty = ParquetConfigurationProperty
set :: PropertyType "ParquetConfiguration" FileFormatConfigurationProperty
-> FileFormatConfigurationProperty
-> FileFormatConfigurationProperty
set PropertyType "ParquetConfiguration" FileFormatConfigurationProperty
newValue FileFormatConfigurationProperty {Maybe Object
Maybe ParquetConfigurationProperty
()
haddock_workaround_ :: FileFormatConfigurationProperty -> ()
jsonConfiguration :: FileFormatConfigurationProperty -> Maybe Object
parquetConfiguration :: FileFormatConfigurationProperty
-> Maybe ParquetConfigurationProperty
haddock_workaround_ :: ()
jsonConfiguration :: Maybe Object
parquetConfiguration :: Maybe ParquetConfigurationProperty
..}
= FileFormatConfigurationProperty
{parquetConfiguration :: Maybe ParquetConfigurationProperty
parquetConfiguration = ParquetConfigurationProperty -> Maybe ParquetConfigurationProperty
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "ParquetConfiguration" FileFormatConfigurationProperty
ParquetConfigurationProperty
newValue, Maybe Object
()
haddock_workaround_ :: ()
jsonConfiguration :: Maybe Object
haddock_workaround_ :: ()
jsonConfiguration :: Maybe Object
..}