{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE DuplicateRecordFields #-}
{-# LANGUAGE NamedFieldPuns #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}
module Amazonka.Glue.Types.S3CsvSource where
import qualified Amazonka.Core as Core
import qualified Amazonka.Core.Lens.Internal as Lens
import qualified Amazonka.Data as Data
import Amazonka.Glue.Types.CompressionType
import Amazonka.Glue.Types.GlueSchema
import Amazonka.Glue.Types.QuoteChar
import Amazonka.Glue.Types.S3DirectSourceAdditionalOptions
import Amazonka.Glue.Types.Separator
import qualified Amazonka.Prelude as Prelude
data S3CsvSource = S3CsvSource'
{
S3CsvSource -> Maybe S3DirectSourceAdditionalOptions
additionalOptions :: Prelude.Maybe S3DirectSourceAdditionalOptions,
S3CsvSource -> Maybe CompressionType
compressionType :: Prelude.Maybe CompressionType,
S3CsvSource -> Maybe Text
escaper :: Prelude.Maybe Prelude.Text,
S3CsvSource -> Maybe [Text]
exclusions :: Prelude.Maybe [Prelude.Text],
S3CsvSource -> Maybe Text
groupFiles :: Prelude.Maybe Prelude.Text,
S3CsvSource -> Maybe Text
groupSize :: Prelude.Maybe Prelude.Text,
S3CsvSource -> Maybe Natural
maxBand :: Prelude.Maybe Prelude.Natural,
S3CsvSource -> Maybe Natural
maxFilesInBand :: Prelude.Maybe Prelude.Natural,
S3CsvSource -> Maybe Bool
multiline :: Prelude.Maybe Prelude.Bool,
S3CsvSource -> Maybe Bool
optimizePerformance :: Prelude.Maybe Prelude.Bool,
S3CsvSource -> Maybe [GlueSchema]
outputSchemas :: Prelude.Maybe [GlueSchema],
S3CsvSource -> Maybe Bool
recurse :: Prelude.Maybe Prelude.Bool,
S3CsvSource -> Maybe Bool
skipFirst :: Prelude.Maybe Prelude.Bool,
:: Prelude.Maybe Prelude.Bool,
:: Prelude.Maybe Prelude.Bool,
S3CsvSource -> Text
name :: Prelude.Text,
S3CsvSource -> [Text]
paths :: [Prelude.Text],
S3CsvSource -> Separator
separator :: Separator,
S3CsvSource -> QuoteChar
quoteChar :: QuoteChar
}
deriving (S3CsvSource -> S3CsvSource -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: S3CsvSource -> S3CsvSource -> Bool
$c/= :: S3CsvSource -> S3CsvSource -> Bool
== :: S3CsvSource -> S3CsvSource -> Bool
$c== :: S3CsvSource -> S3CsvSource -> Bool
Prelude.Eq, ReadPrec [S3CsvSource]
ReadPrec S3CsvSource
Int -> ReadS S3CsvSource
ReadS [S3CsvSource]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [S3CsvSource]
$creadListPrec :: ReadPrec [S3CsvSource]
readPrec :: ReadPrec S3CsvSource
$creadPrec :: ReadPrec S3CsvSource
readList :: ReadS [S3CsvSource]
$creadList :: ReadS [S3CsvSource]
readsPrec :: Int -> ReadS S3CsvSource
$creadsPrec :: Int -> ReadS S3CsvSource
Prelude.Read, Int -> S3CsvSource -> ShowS
[S3CsvSource] -> ShowS
S3CsvSource -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [S3CsvSource] -> ShowS
$cshowList :: [S3CsvSource] -> ShowS
show :: S3CsvSource -> String
$cshow :: S3CsvSource -> String
showsPrec :: Int -> S3CsvSource -> ShowS
$cshowsPrec :: Int -> S3CsvSource -> ShowS
Prelude.Show, forall x. Rep S3CsvSource x -> S3CsvSource
forall x. S3CsvSource -> Rep S3CsvSource x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep S3CsvSource x -> S3CsvSource
$cfrom :: forall x. S3CsvSource -> Rep S3CsvSource x
Prelude.Generic)
newS3CsvSource ::
Prelude.Text ->
Separator ->
QuoteChar ->
S3CsvSource
newS3CsvSource :: Text -> Separator -> QuoteChar -> S3CsvSource
newS3CsvSource Text
pName_ Separator
pSeparator_ QuoteChar
pQuoteChar_ =
S3CsvSource'
{ $sel:additionalOptions:S3CsvSource' :: Maybe S3DirectSourceAdditionalOptions
additionalOptions = forall a. Maybe a
Prelude.Nothing,
$sel:compressionType:S3CsvSource' :: Maybe CompressionType
compressionType = forall a. Maybe a
Prelude.Nothing,
$sel:escaper:S3CsvSource' :: Maybe Text
escaper = forall a. Maybe a
Prelude.Nothing,
$sel:exclusions:S3CsvSource' :: Maybe [Text]
exclusions = forall a. Maybe a
Prelude.Nothing,
$sel:groupFiles:S3CsvSource' :: Maybe Text
groupFiles = forall a. Maybe a
Prelude.Nothing,
$sel:groupSize:S3CsvSource' :: Maybe Text
groupSize = forall a. Maybe a
Prelude.Nothing,
$sel:maxBand:S3CsvSource' :: Maybe Natural
maxBand = forall a. Maybe a
Prelude.Nothing,
$sel:maxFilesInBand:S3CsvSource' :: Maybe Natural
maxFilesInBand = forall a. Maybe a
Prelude.Nothing,
$sel:multiline:S3CsvSource' :: Maybe Bool
multiline = forall a. Maybe a
Prelude.Nothing,
$sel:optimizePerformance:S3CsvSource' :: Maybe Bool
optimizePerformance = forall a. Maybe a
Prelude.Nothing,
$sel:outputSchemas:S3CsvSource' :: Maybe [GlueSchema]
outputSchemas = forall a. Maybe a
Prelude.Nothing,
$sel:recurse:S3CsvSource' :: Maybe Bool
recurse = forall a. Maybe a
Prelude.Nothing,
$sel:skipFirst:S3CsvSource' :: Maybe Bool
skipFirst = forall a. Maybe a
Prelude.Nothing,
$sel:withHeader:S3CsvSource' :: Maybe Bool
withHeader = forall a. Maybe a
Prelude.Nothing,
$sel:writeHeader:S3CsvSource' :: Maybe Bool
writeHeader = forall a. Maybe a
Prelude.Nothing,
$sel:name:S3CsvSource' :: Text
name = Text
pName_,
$sel:paths:S3CsvSource' :: [Text]
paths = forall a. Monoid a => a
Prelude.mempty,
$sel:separator:S3CsvSource' :: Separator
separator = Separator
pSeparator_,
$sel:quoteChar:S3CsvSource' :: QuoteChar
quoteChar = QuoteChar
pQuoteChar_
}
s3CsvSource_additionalOptions :: Lens.Lens' S3CsvSource (Prelude.Maybe S3DirectSourceAdditionalOptions)
s3CsvSource_additionalOptions :: Lens' S3CsvSource (Maybe S3DirectSourceAdditionalOptions)
s3CsvSource_additionalOptions = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\S3CsvSource' {Maybe S3DirectSourceAdditionalOptions
additionalOptions :: Maybe S3DirectSourceAdditionalOptions
$sel:additionalOptions:S3CsvSource' :: S3CsvSource -> Maybe S3DirectSourceAdditionalOptions
additionalOptions} -> Maybe S3DirectSourceAdditionalOptions
additionalOptions) (\s :: S3CsvSource
s@S3CsvSource' {} Maybe S3DirectSourceAdditionalOptions
a -> S3CsvSource
s {$sel:additionalOptions:S3CsvSource' :: Maybe S3DirectSourceAdditionalOptions
additionalOptions = Maybe S3DirectSourceAdditionalOptions
a} :: S3CsvSource)
s3CsvSource_compressionType :: Lens.Lens' S3CsvSource (Prelude.Maybe CompressionType)
s3CsvSource_compressionType :: Lens' S3CsvSource (Maybe CompressionType)
s3CsvSource_compressionType = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\S3CsvSource' {Maybe CompressionType
compressionType :: Maybe CompressionType
$sel:compressionType:S3CsvSource' :: S3CsvSource -> Maybe CompressionType
compressionType} -> Maybe CompressionType
compressionType) (\s :: S3CsvSource
s@S3CsvSource' {} Maybe CompressionType
a -> S3CsvSource
s {$sel:compressionType:S3CsvSource' :: Maybe CompressionType
compressionType = Maybe CompressionType
a} :: S3CsvSource)
s3CsvSource_escaper :: Lens.Lens' S3CsvSource (Prelude.Maybe Prelude.Text)
s3CsvSource_escaper :: Lens' S3CsvSource (Maybe Text)
s3CsvSource_escaper = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\S3CsvSource' {Maybe Text
escaper :: Maybe Text
$sel:escaper:S3CsvSource' :: S3CsvSource -> Maybe Text
escaper} -> Maybe Text
escaper) (\s :: S3CsvSource
s@S3CsvSource' {} Maybe Text
a -> S3CsvSource
s {$sel:escaper:S3CsvSource' :: Maybe Text
escaper = Maybe Text
a} :: S3CsvSource)
s3CsvSource_exclusions :: Lens.Lens' S3CsvSource (Prelude.Maybe [Prelude.Text])
s3CsvSource_exclusions :: Lens' S3CsvSource (Maybe [Text])
s3CsvSource_exclusions = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\S3CsvSource' {Maybe [Text]
exclusions :: Maybe [Text]
$sel:exclusions:S3CsvSource' :: S3CsvSource -> Maybe [Text]
exclusions} -> Maybe [Text]
exclusions) (\s :: S3CsvSource
s@S3CsvSource' {} Maybe [Text]
a -> S3CsvSource
s {$sel:exclusions:S3CsvSource' :: Maybe [Text]
exclusions = Maybe [Text]
a} :: S3CsvSource) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
s3CsvSource_groupFiles :: Lens.Lens' S3CsvSource (Prelude.Maybe Prelude.Text)
s3CsvSource_groupFiles :: Lens' S3CsvSource (Maybe Text)
s3CsvSource_groupFiles = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\S3CsvSource' {Maybe Text
groupFiles :: Maybe Text
$sel:groupFiles:S3CsvSource' :: S3CsvSource -> Maybe Text
groupFiles} -> Maybe Text
groupFiles) (\s :: S3CsvSource
s@S3CsvSource' {} Maybe Text
a -> S3CsvSource
s {$sel:groupFiles:S3CsvSource' :: Maybe Text
groupFiles = Maybe Text
a} :: S3CsvSource)
s3CsvSource_groupSize :: Lens.Lens' S3CsvSource (Prelude.Maybe Prelude.Text)
s3CsvSource_groupSize :: Lens' S3CsvSource (Maybe Text)
s3CsvSource_groupSize = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\S3CsvSource' {Maybe Text
groupSize :: Maybe Text
$sel:groupSize:S3CsvSource' :: S3CsvSource -> Maybe Text
groupSize} -> Maybe Text
groupSize) (\s :: S3CsvSource
s@S3CsvSource' {} Maybe Text
a -> S3CsvSource
s {$sel:groupSize:S3CsvSource' :: Maybe Text
groupSize = Maybe Text
a} :: S3CsvSource)
s3CsvSource_maxBand :: Lens.Lens' S3CsvSource (Prelude.Maybe Prelude.Natural)
s3CsvSource_maxBand :: Lens' S3CsvSource (Maybe Natural)
s3CsvSource_maxBand = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\S3CsvSource' {Maybe Natural
maxBand :: Maybe Natural
$sel:maxBand:S3CsvSource' :: S3CsvSource -> Maybe Natural
maxBand} -> Maybe Natural
maxBand) (\s :: S3CsvSource
s@S3CsvSource' {} Maybe Natural
a -> S3CsvSource
s {$sel:maxBand:S3CsvSource' :: Maybe Natural
maxBand = Maybe Natural
a} :: S3CsvSource)
s3CsvSource_maxFilesInBand :: Lens.Lens' S3CsvSource (Prelude.Maybe Prelude.Natural)
s3CsvSource_maxFilesInBand :: Lens' S3CsvSource (Maybe Natural)
s3CsvSource_maxFilesInBand = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\S3CsvSource' {Maybe Natural
maxFilesInBand :: Maybe Natural
$sel:maxFilesInBand:S3CsvSource' :: S3CsvSource -> Maybe Natural
maxFilesInBand} -> Maybe Natural
maxFilesInBand) (\s :: S3CsvSource
s@S3CsvSource' {} Maybe Natural
a -> S3CsvSource
s {$sel:maxFilesInBand:S3CsvSource' :: Maybe Natural
maxFilesInBand = Maybe Natural
a} :: S3CsvSource)
s3CsvSource_multiline :: Lens.Lens' S3CsvSource (Prelude.Maybe Prelude.Bool)
s3CsvSource_multiline :: Lens' S3CsvSource (Maybe Bool)
s3CsvSource_multiline = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\S3CsvSource' {Maybe Bool
multiline :: Maybe Bool
$sel:multiline:S3CsvSource' :: S3CsvSource -> Maybe Bool
multiline} -> Maybe Bool
multiline) (\s :: S3CsvSource
s@S3CsvSource' {} Maybe Bool
a -> S3CsvSource
s {$sel:multiline:S3CsvSource' :: Maybe Bool
multiline = Maybe Bool
a} :: S3CsvSource)
s3CsvSource_optimizePerformance :: Lens.Lens' S3CsvSource (Prelude.Maybe Prelude.Bool)
s3CsvSource_optimizePerformance :: Lens' S3CsvSource (Maybe Bool)
s3CsvSource_optimizePerformance = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\S3CsvSource' {Maybe Bool
optimizePerformance :: Maybe Bool
$sel:optimizePerformance:S3CsvSource' :: S3CsvSource -> Maybe Bool
optimizePerformance} -> Maybe Bool
optimizePerformance) (\s :: S3CsvSource
s@S3CsvSource' {} Maybe Bool
a -> S3CsvSource
s {$sel:optimizePerformance:S3CsvSource' :: Maybe Bool
optimizePerformance = Maybe Bool
a} :: S3CsvSource)
s3CsvSource_outputSchemas :: Lens.Lens' S3CsvSource (Prelude.Maybe [GlueSchema])
s3CsvSource_outputSchemas :: Lens' S3CsvSource (Maybe [GlueSchema])
s3CsvSource_outputSchemas = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\S3CsvSource' {Maybe [GlueSchema]
outputSchemas :: Maybe [GlueSchema]
$sel:outputSchemas:S3CsvSource' :: S3CsvSource -> Maybe [GlueSchema]
outputSchemas} -> Maybe [GlueSchema]
outputSchemas) (\s :: S3CsvSource
s@S3CsvSource' {} Maybe [GlueSchema]
a -> S3CsvSource
s {$sel:outputSchemas:S3CsvSource' :: Maybe [GlueSchema]
outputSchemas = Maybe [GlueSchema]
a} :: S3CsvSource) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
s3CsvSource_recurse :: Lens.Lens' S3CsvSource (Prelude.Maybe Prelude.Bool)
s3CsvSource_recurse :: Lens' S3CsvSource (Maybe Bool)
s3CsvSource_recurse = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\S3CsvSource' {Maybe Bool
recurse :: Maybe Bool
$sel:recurse:S3CsvSource' :: S3CsvSource -> Maybe Bool
recurse} -> Maybe Bool
recurse) (\s :: S3CsvSource
s@S3CsvSource' {} Maybe Bool
a -> S3CsvSource
s {$sel:recurse:S3CsvSource' :: Maybe Bool
recurse = Maybe Bool
a} :: S3CsvSource)
s3CsvSource_skipFirst :: Lens.Lens' S3CsvSource (Prelude.Maybe Prelude.Bool)
s3CsvSource_skipFirst :: Lens' S3CsvSource (Maybe Bool)
s3CsvSource_skipFirst = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\S3CsvSource' {Maybe Bool
skipFirst :: Maybe Bool
$sel:skipFirst:S3CsvSource' :: S3CsvSource -> Maybe Bool
skipFirst} -> Maybe Bool
skipFirst) (\s :: S3CsvSource
s@S3CsvSource' {} Maybe Bool
a -> S3CsvSource
s {$sel:skipFirst:S3CsvSource' :: Maybe Bool
skipFirst = Maybe Bool
a} :: S3CsvSource)
s3CsvSource_withHeader :: Lens.Lens' S3CsvSource (Prelude.Maybe Prelude.Bool)
= forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\S3CsvSource' {Maybe Bool
withHeader :: Maybe Bool
$sel:withHeader:S3CsvSource' :: S3CsvSource -> Maybe Bool
withHeader} -> Maybe Bool
withHeader) (\s :: S3CsvSource
s@S3CsvSource' {} Maybe Bool
a -> S3CsvSource
s {$sel:withHeader:S3CsvSource' :: Maybe Bool
withHeader = Maybe Bool
a} :: S3CsvSource)
s3CsvSource_writeHeader :: Lens.Lens' S3CsvSource (Prelude.Maybe Prelude.Bool)
= forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\S3CsvSource' {Maybe Bool
writeHeader :: Maybe Bool
$sel:writeHeader:S3CsvSource' :: S3CsvSource -> Maybe Bool
writeHeader} -> Maybe Bool
writeHeader) (\s :: S3CsvSource
s@S3CsvSource' {} Maybe Bool
a -> S3CsvSource
s {$sel:writeHeader:S3CsvSource' :: Maybe Bool
writeHeader = Maybe Bool
a} :: S3CsvSource)
s3CsvSource_name :: Lens.Lens' S3CsvSource Prelude.Text
s3CsvSource_name :: Lens' S3CsvSource Text
s3CsvSource_name = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\S3CsvSource' {Text
name :: Text
$sel:name:S3CsvSource' :: S3CsvSource -> Text
name} -> Text
name) (\s :: S3CsvSource
s@S3CsvSource' {} Text
a -> S3CsvSource
s {$sel:name:S3CsvSource' :: Text
name = Text
a} :: S3CsvSource)
s3CsvSource_paths :: Lens.Lens' S3CsvSource [Prelude.Text]
s3CsvSource_paths :: Lens' S3CsvSource [Text]
s3CsvSource_paths = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\S3CsvSource' {[Text]
paths :: [Text]
$sel:paths:S3CsvSource' :: S3CsvSource -> [Text]
paths} -> [Text]
paths) (\s :: S3CsvSource
s@S3CsvSource' {} [Text]
a -> S3CsvSource
s {$sel:paths:S3CsvSource' :: [Text]
paths = [Text]
a} :: S3CsvSource) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
s3CsvSource_separator :: Lens.Lens' S3CsvSource Separator
s3CsvSource_separator :: Lens' S3CsvSource Separator
s3CsvSource_separator = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\S3CsvSource' {Separator
separator :: Separator
$sel:separator:S3CsvSource' :: S3CsvSource -> Separator
separator} -> Separator
separator) (\s :: S3CsvSource
s@S3CsvSource' {} Separator
a -> S3CsvSource
s {$sel:separator:S3CsvSource' :: Separator
separator = Separator
a} :: S3CsvSource)
s3CsvSource_quoteChar :: Lens.Lens' S3CsvSource QuoteChar
s3CsvSource_quoteChar :: Lens' S3CsvSource QuoteChar
s3CsvSource_quoteChar = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\S3CsvSource' {QuoteChar
quoteChar :: QuoteChar
$sel:quoteChar:S3CsvSource' :: S3CsvSource -> QuoteChar
quoteChar} -> QuoteChar
quoteChar) (\s :: S3CsvSource
s@S3CsvSource' {} QuoteChar
a -> S3CsvSource
s {$sel:quoteChar:S3CsvSource' :: QuoteChar
quoteChar = QuoteChar
a} :: S3CsvSource)
instance Data.FromJSON S3CsvSource where
parseJSON :: Value -> Parser S3CsvSource
parseJSON =
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.withObject
String
"S3CsvSource"
( \Object
x ->
Maybe S3DirectSourceAdditionalOptions
-> Maybe CompressionType
-> Maybe Text
-> Maybe [Text]
-> Maybe Text
-> Maybe Text
-> Maybe Natural
-> Maybe Natural
-> Maybe Bool
-> Maybe Bool
-> Maybe [GlueSchema]
-> Maybe Bool
-> Maybe Bool
-> Maybe Bool
-> Maybe Bool
-> Text
-> [Text]
-> Separator
-> QuoteChar
-> S3CsvSource
S3CsvSource'
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"AdditionalOptions")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"CompressionType")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"Escaper")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"Exclusions" forall a. Parser (Maybe a) -> a -> Parser a
Data..!= forall a. Monoid a => a
Prelude.mempty)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"GroupFiles")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"GroupSize")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"MaxBand")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"MaxFilesInBand")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"Multiline")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"OptimizePerformance")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"OutputSchemas" forall a. Parser (Maybe a) -> a -> Parser a
Data..!= forall a. Monoid a => a
Prelude.mempty)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"Recurse")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"SkipFirst")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"WithHeader")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"WriteHeader")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser a
Data..: Key
"Name")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"Paths" forall a. Parser (Maybe a) -> a -> Parser a
Data..!= forall a. Monoid a => a
Prelude.mempty)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser a
Data..: Key
"Separator")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser a
Data..: Key
"QuoteChar")
)
instance Prelude.Hashable S3CsvSource where
hashWithSalt :: Int -> S3CsvSource -> Int
hashWithSalt Int
_salt S3CsvSource' {[Text]
Maybe Bool
Maybe Natural
Maybe [Text]
Maybe [GlueSchema]
Maybe Text
Maybe CompressionType
Maybe S3DirectSourceAdditionalOptions
Text
QuoteChar
Separator
quoteChar :: QuoteChar
separator :: Separator
paths :: [Text]
name :: Text
writeHeader :: Maybe Bool
withHeader :: Maybe Bool
skipFirst :: Maybe Bool
recurse :: Maybe Bool
outputSchemas :: Maybe [GlueSchema]
optimizePerformance :: Maybe Bool
multiline :: Maybe Bool
maxFilesInBand :: Maybe Natural
maxBand :: Maybe Natural
groupSize :: Maybe Text
groupFiles :: Maybe Text
exclusions :: Maybe [Text]
escaper :: Maybe Text
compressionType :: Maybe CompressionType
additionalOptions :: Maybe S3DirectSourceAdditionalOptions
$sel:quoteChar:S3CsvSource' :: S3CsvSource -> QuoteChar
$sel:separator:S3CsvSource' :: S3CsvSource -> Separator
$sel:paths:S3CsvSource' :: S3CsvSource -> [Text]
$sel:name:S3CsvSource' :: S3CsvSource -> Text
$sel:writeHeader:S3CsvSource' :: S3CsvSource -> Maybe Bool
$sel:withHeader:S3CsvSource' :: S3CsvSource -> Maybe Bool
$sel:skipFirst:S3CsvSource' :: S3CsvSource -> Maybe Bool
$sel:recurse:S3CsvSource' :: S3CsvSource -> Maybe Bool
$sel:outputSchemas:S3CsvSource' :: S3CsvSource -> Maybe [GlueSchema]
$sel:optimizePerformance:S3CsvSource' :: S3CsvSource -> Maybe Bool
$sel:multiline:S3CsvSource' :: S3CsvSource -> Maybe Bool
$sel:maxFilesInBand:S3CsvSource' :: S3CsvSource -> Maybe Natural
$sel:maxBand:S3CsvSource' :: S3CsvSource -> Maybe Natural
$sel:groupSize:S3CsvSource' :: S3CsvSource -> Maybe Text
$sel:groupFiles:S3CsvSource' :: S3CsvSource -> Maybe Text
$sel:exclusions:S3CsvSource' :: S3CsvSource -> Maybe [Text]
$sel:escaper:S3CsvSource' :: S3CsvSource -> Maybe Text
$sel:compressionType:S3CsvSource' :: S3CsvSource -> Maybe CompressionType
$sel:additionalOptions:S3CsvSource' :: S3CsvSource -> Maybe S3DirectSourceAdditionalOptions
..} =
Int
_salt
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe S3DirectSourceAdditionalOptions
additionalOptions
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe CompressionType
compressionType
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
escaper
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe [Text]
exclusions
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
groupFiles
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
groupSize
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Natural
maxBand
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Natural
maxFilesInBand
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Bool
multiline
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Bool
optimizePerformance
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe [GlueSchema]
outputSchemas
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Bool
recurse
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Bool
skipFirst
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Bool
withHeader
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Bool
writeHeader
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
name
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` [Text]
paths
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Separator
separator
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` QuoteChar
quoteChar
instance Prelude.NFData S3CsvSource where
rnf :: S3CsvSource -> ()
rnf S3CsvSource' {[Text]
Maybe Bool
Maybe Natural
Maybe [Text]
Maybe [GlueSchema]
Maybe Text
Maybe CompressionType
Maybe S3DirectSourceAdditionalOptions
Text
QuoteChar
Separator
quoteChar :: QuoteChar
separator :: Separator
paths :: [Text]
name :: Text
writeHeader :: Maybe Bool
withHeader :: Maybe Bool
skipFirst :: Maybe Bool
recurse :: Maybe Bool
outputSchemas :: Maybe [GlueSchema]
optimizePerformance :: Maybe Bool
multiline :: Maybe Bool
maxFilesInBand :: Maybe Natural
maxBand :: Maybe Natural
groupSize :: Maybe Text
groupFiles :: Maybe Text
exclusions :: Maybe [Text]
escaper :: Maybe Text
compressionType :: Maybe CompressionType
additionalOptions :: Maybe S3DirectSourceAdditionalOptions
$sel:quoteChar:S3CsvSource' :: S3CsvSource -> QuoteChar
$sel:separator:S3CsvSource' :: S3CsvSource -> Separator
$sel:paths:S3CsvSource' :: S3CsvSource -> [Text]
$sel:name:S3CsvSource' :: S3CsvSource -> Text
$sel:writeHeader:S3CsvSource' :: S3CsvSource -> Maybe Bool
$sel:withHeader:S3CsvSource' :: S3CsvSource -> Maybe Bool
$sel:skipFirst:S3CsvSource' :: S3CsvSource -> Maybe Bool
$sel:recurse:S3CsvSource' :: S3CsvSource -> Maybe Bool
$sel:outputSchemas:S3CsvSource' :: S3CsvSource -> Maybe [GlueSchema]
$sel:optimizePerformance:S3CsvSource' :: S3CsvSource -> Maybe Bool
$sel:multiline:S3CsvSource' :: S3CsvSource -> Maybe Bool
$sel:maxFilesInBand:S3CsvSource' :: S3CsvSource -> Maybe Natural
$sel:maxBand:S3CsvSource' :: S3CsvSource -> Maybe Natural
$sel:groupSize:S3CsvSource' :: S3CsvSource -> Maybe Text
$sel:groupFiles:S3CsvSource' :: S3CsvSource -> Maybe Text
$sel:exclusions:S3CsvSource' :: S3CsvSource -> Maybe [Text]
$sel:escaper:S3CsvSource' :: S3CsvSource -> Maybe Text
$sel:compressionType:S3CsvSource' :: S3CsvSource -> Maybe CompressionType
$sel:additionalOptions:S3CsvSource' :: S3CsvSource -> Maybe S3DirectSourceAdditionalOptions
..} =
forall a. NFData a => a -> ()
Prelude.rnf Maybe S3DirectSourceAdditionalOptions
additionalOptions
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe CompressionType
compressionType
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
escaper
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe [Text]
exclusions
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
groupFiles
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
groupSize
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Natural
maxBand
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Natural
maxFilesInBand
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Bool
multiline
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Bool
optimizePerformance
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe [GlueSchema]
outputSchemas
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Bool
recurse
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Bool
skipFirst
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Bool
withHeader
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Bool
writeHeader
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
name
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf [Text]
paths
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Separator
separator
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf QuoteChar
quoteChar
instance Data.ToJSON S3CsvSource where
toJSON :: S3CsvSource -> Value
toJSON S3CsvSource' {[Text]
Maybe Bool
Maybe Natural
Maybe [Text]
Maybe [GlueSchema]
Maybe Text
Maybe CompressionType
Maybe S3DirectSourceAdditionalOptions
Text
QuoteChar
Separator
quoteChar :: QuoteChar
separator :: Separator
paths :: [Text]
name :: Text
writeHeader :: Maybe Bool
withHeader :: Maybe Bool
skipFirst :: Maybe Bool
recurse :: Maybe Bool
outputSchemas :: Maybe [GlueSchema]
optimizePerformance :: Maybe Bool
multiline :: Maybe Bool
maxFilesInBand :: Maybe Natural
maxBand :: Maybe Natural
groupSize :: Maybe Text
groupFiles :: Maybe Text
exclusions :: Maybe [Text]
escaper :: Maybe Text
compressionType :: Maybe CompressionType
additionalOptions :: Maybe S3DirectSourceAdditionalOptions
$sel:quoteChar:S3CsvSource' :: S3CsvSource -> QuoteChar
$sel:separator:S3CsvSource' :: S3CsvSource -> Separator
$sel:paths:S3CsvSource' :: S3CsvSource -> [Text]
$sel:name:S3CsvSource' :: S3CsvSource -> Text
$sel:writeHeader:S3CsvSource' :: S3CsvSource -> Maybe Bool
$sel:withHeader:S3CsvSource' :: S3CsvSource -> Maybe Bool
$sel:skipFirst:S3CsvSource' :: S3CsvSource -> Maybe Bool
$sel:recurse:S3CsvSource' :: S3CsvSource -> Maybe Bool
$sel:outputSchemas:S3CsvSource' :: S3CsvSource -> Maybe [GlueSchema]
$sel:optimizePerformance:S3CsvSource' :: S3CsvSource -> Maybe Bool
$sel:multiline:S3CsvSource' :: S3CsvSource -> Maybe Bool
$sel:maxFilesInBand:S3CsvSource' :: S3CsvSource -> Maybe Natural
$sel:maxBand:S3CsvSource' :: S3CsvSource -> Maybe Natural
$sel:groupSize:S3CsvSource' :: S3CsvSource -> Maybe Text
$sel:groupFiles:S3CsvSource' :: S3CsvSource -> Maybe Text
$sel:exclusions:S3CsvSource' :: S3CsvSource -> Maybe [Text]
$sel:escaper:S3CsvSource' :: S3CsvSource -> Maybe Text
$sel:compressionType:S3CsvSource' :: S3CsvSource -> Maybe CompressionType
$sel:additionalOptions:S3CsvSource' :: S3CsvSource -> Maybe S3DirectSourceAdditionalOptions
..} =
[Pair] -> Value
Data.object
( forall a. [Maybe a] -> [a]
Prelude.catMaybes
[ (Key
"AdditionalOptions" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe S3DirectSourceAdditionalOptions
additionalOptions,
(Key
"CompressionType" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe CompressionType
compressionType,
(Key
"Escaper" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
escaper,
(Key
"Exclusions" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [Text]
exclusions,
(Key
"GroupFiles" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
groupFiles,
(Key
"GroupSize" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
groupSize,
(Key
"MaxBand" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Natural
maxBand,
(Key
"MaxFilesInBand" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Natural
maxFilesInBand,
(Key
"Multiline" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Bool
multiline,
(Key
"OptimizePerformance" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Bool
optimizePerformance,
(Key
"OutputSchemas" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [GlueSchema]
outputSchemas,
(Key
"Recurse" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Bool
recurse,
(Key
"SkipFirst" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Bool
skipFirst,
(Key
"WithHeader" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Bool
withHeader,
(Key
"WriteHeader" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Bool
writeHeader,
forall a. a -> Maybe a
Prelude.Just (Key
"Name" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..= Text
name),
forall a. a -> Maybe a
Prelude.Just (Key
"Paths" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..= [Text]
paths),
forall a. a -> Maybe a
Prelude.Just (Key
"Separator" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..= Separator
separator),
forall a. a -> Maybe a
Prelude.Just (Key
"QuoteChar" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..= QuoteChar
quoteChar)
]
)