{-# 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.DataBrew.Types.S3TableOutputOptions where
import qualified Amazonka.Core as Core
import qualified Amazonka.Core.Lens.Internal as Lens
import qualified Amazonka.Data as Data
import Amazonka.DataBrew.Types.S3Location
import qualified Amazonka.Prelude as Prelude
data S3TableOutputOptions = S3TableOutputOptions'
{
S3TableOutputOptions -> S3Location
location :: S3Location
}
deriving (S3TableOutputOptions -> S3TableOutputOptions -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: S3TableOutputOptions -> S3TableOutputOptions -> Bool
$c/= :: S3TableOutputOptions -> S3TableOutputOptions -> Bool
== :: S3TableOutputOptions -> S3TableOutputOptions -> Bool
$c== :: S3TableOutputOptions -> S3TableOutputOptions -> Bool
Prelude.Eq, ReadPrec [S3TableOutputOptions]
ReadPrec S3TableOutputOptions
Int -> ReadS S3TableOutputOptions
ReadS [S3TableOutputOptions]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [S3TableOutputOptions]
$creadListPrec :: ReadPrec [S3TableOutputOptions]
readPrec :: ReadPrec S3TableOutputOptions
$creadPrec :: ReadPrec S3TableOutputOptions
readList :: ReadS [S3TableOutputOptions]
$creadList :: ReadS [S3TableOutputOptions]
readsPrec :: Int -> ReadS S3TableOutputOptions
$creadsPrec :: Int -> ReadS S3TableOutputOptions
Prelude.Read, Int -> S3TableOutputOptions -> ShowS
[S3TableOutputOptions] -> ShowS
S3TableOutputOptions -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [S3TableOutputOptions] -> ShowS
$cshowList :: [S3TableOutputOptions] -> ShowS
show :: S3TableOutputOptions -> String
$cshow :: S3TableOutputOptions -> String
showsPrec :: Int -> S3TableOutputOptions -> ShowS
$cshowsPrec :: Int -> S3TableOutputOptions -> ShowS
Prelude.Show, forall x. Rep S3TableOutputOptions x -> S3TableOutputOptions
forall x. S3TableOutputOptions -> Rep S3TableOutputOptions x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep S3TableOutputOptions x -> S3TableOutputOptions
$cfrom :: forall x. S3TableOutputOptions -> Rep S3TableOutputOptions x
Prelude.Generic)
newS3TableOutputOptions ::
S3Location ->
S3TableOutputOptions
newS3TableOutputOptions :: S3Location -> S3TableOutputOptions
newS3TableOutputOptions S3Location
pLocation_ =
S3TableOutputOptions' {$sel:location:S3TableOutputOptions' :: S3Location
location = S3Location
pLocation_}
s3TableOutputOptions_location :: Lens.Lens' S3TableOutputOptions S3Location
s3TableOutputOptions_location :: Lens' S3TableOutputOptions S3Location
s3TableOutputOptions_location = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\S3TableOutputOptions' {S3Location
location :: S3Location
$sel:location:S3TableOutputOptions' :: S3TableOutputOptions -> S3Location
location} -> S3Location
location) (\s :: S3TableOutputOptions
s@S3TableOutputOptions' {} S3Location
a -> S3TableOutputOptions
s {$sel:location:S3TableOutputOptions' :: S3Location
location = S3Location
a} :: S3TableOutputOptions)
instance Data.FromJSON S3TableOutputOptions where
parseJSON :: Value -> Parser S3TableOutputOptions
parseJSON =
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.withObject
String
"S3TableOutputOptions"
( \Object
x ->
S3Location -> S3TableOutputOptions
S3TableOutputOptions'
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x forall a. FromJSON a => Object -> Key -> Parser a
Data..: Key
"Location")
)
instance Prelude.Hashable S3TableOutputOptions where
hashWithSalt :: Int -> S3TableOutputOptions -> Int
hashWithSalt Int
_salt S3TableOutputOptions' {S3Location
location :: S3Location
$sel:location:S3TableOutputOptions' :: S3TableOutputOptions -> S3Location
..} =
Int
_salt forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` S3Location
location
instance Prelude.NFData S3TableOutputOptions where
rnf :: S3TableOutputOptions -> ()
rnf S3TableOutputOptions' {S3Location
location :: S3Location
$sel:location:S3TableOutputOptions' :: S3TableOutputOptions -> S3Location
..} = forall a. NFData a => a -> ()
Prelude.rnf S3Location
location
instance Data.ToJSON S3TableOutputOptions where
toJSON :: S3TableOutputOptions -> Value
toJSON S3TableOutputOptions' {S3Location
location :: S3Location
$sel:location:S3TableOutputOptions' :: S3TableOutputOptions -> S3Location
..} =
[Pair] -> Value
Data.object
( forall a. [Maybe a] -> [a]
Prelude.catMaybes
[forall a. a -> Maybe a
Prelude.Just (Key
"Location" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..= S3Location
location)]
)