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