{-# 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.BatchUpdatePartitionRequestEntry 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.PartitionInput
import qualified Amazonka.Prelude as Prelude
data BatchUpdatePartitionRequestEntry = BatchUpdatePartitionRequestEntry'
{
BatchUpdatePartitionRequestEntry -> [Text]
partitionValueList :: [Prelude.Text],
BatchUpdatePartitionRequestEntry -> PartitionInput
partitionInput :: PartitionInput
}
deriving (BatchUpdatePartitionRequestEntry
-> BatchUpdatePartitionRequestEntry -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: BatchUpdatePartitionRequestEntry
-> BatchUpdatePartitionRequestEntry -> Bool
$c/= :: BatchUpdatePartitionRequestEntry
-> BatchUpdatePartitionRequestEntry -> Bool
== :: BatchUpdatePartitionRequestEntry
-> BatchUpdatePartitionRequestEntry -> Bool
$c== :: BatchUpdatePartitionRequestEntry
-> BatchUpdatePartitionRequestEntry -> Bool
Prelude.Eq, ReadPrec [BatchUpdatePartitionRequestEntry]
ReadPrec BatchUpdatePartitionRequestEntry
Int -> ReadS BatchUpdatePartitionRequestEntry
ReadS [BatchUpdatePartitionRequestEntry]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [BatchUpdatePartitionRequestEntry]
$creadListPrec :: ReadPrec [BatchUpdatePartitionRequestEntry]
readPrec :: ReadPrec BatchUpdatePartitionRequestEntry
$creadPrec :: ReadPrec BatchUpdatePartitionRequestEntry
readList :: ReadS [BatchUpdatePartitionRequestEntry]
$creadList :: ReadS [BatchUpdatePartitionRequestEntry]
readsPrec :: Int -> ReadS BatchUpdatePartitionRequestEntry
$creadsPrec :: Int -> ReadS BatchUpdatePartitionRequestEntry
Prelude.Read, Int -> BatchUpdatePartitionRequestEntry -> ShowS
[BatchUpdatePartitionRequestEntry] -> ShowS
BatchUpdatePartitionRequestEntry -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [BatchUpdatePartitionRequestEntry] -> ShowS
$cshowList :: [BatchUpdatePartitionRequestEntry] -> ShowS
show :: BatchUpdatePartitionRequestEntry -> String
$cshow :: BatchUpdatePartitionRequestEntry -> String
showsPrec :: Int -> BatchUpdatePartitionRequestEntry -> ShowS
$cshowsPrec :: Int -> BatchUpdatePartitionRequestEntry -> ShowS
Prelude.Show, forall x.
Rep BatchUpdatePartitionRequestEntry x
-> BatchUpdatePartitionRequestEntry
forall x.
BatchUpdatePartitionRequestEntry
-> Rep BatchUpdatePartitionRequestEntry x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep BatchUpdatePartitionRequestEntry x
-> BatchUpdatePartitionRequestEntry
$cfrom :: forall x.
BatchUpdatePartitionRequestEntry
-> Rep BatchUpdatePartitionRequestEntry x
Prelude.Generic)
newBatchUpdatePartitionRequestEntry ::
PartitionInput ->
BatchUpdatePartitionRequestEntry
newBatchUpdatePartitionRequestEntry :: PartitionInput -> BatchUpdatePartitionRequestEntry
newBatchUpdatePartitionRequestEntry PartitionInput
pPartitionInput_ =
BatchUpdatePartitionRequestEntry'
{ $sel:partitionValueList:BatchUpdatePartitionRequestEntry' :: [Text]
partitionValueList =
forall a. Monoid a => a
Prelude.mempty,
$sel:partitionInput:BatchUpdatePartitionRequestEntry' :: PartitionInput
partitionInput = PartitionInput
pPartitionInput_
}
batchUpdatePartitionRequestEntry_partitionValueList :: Lens.Lens' BatchUpdatePartitionRequestEntry [Prelude.Text]
batchUpdatePartitionRequestEntry_partitionValueList :: Lens' BatchUpdatePartitionRequestEntry [Text]
batchUpdatePartitionRequestEntry_partitionValueList = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\BatchUpdatePartitionRequestEntry' {[Text]
partitionValueList :: [Text]
$sel:partitionValueList:BatchUpdatePartitionRequestEntry' :: BatchUpdatePartitionRequestEntry -> [Text]
partitionValueList} -> [Text]
partitionValueList) (\s :: BatchUpdatePartitionRequestEntry
s@BatchUpdatePartitionRequestEntry' {} [Text]
a -> BatchUpdatePartitionRequestEntry
s {$sel:partitionValueList:BatchUpdatePartitionRequestEntry' :: [Text]
partitionValueList = [Text]
a} :: BatchUpdatePartitionRequestEntry) 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
batchUpdatePartitionRequestEntry_partitionInput :: Lens.Lens' BatchUpdatePartitionRequestEntry PartitionInput
batchUpdatePartitionRequestEntry_partitionInput :: Lens' BatchUpdatePartitionRequestEntry PartitionInput
batchUpdatePartitionRequestEntry_partitionInput = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\BatchUpdatePartitionRequestEntry' {PartitionInput
partitionInput :: PartitionInput
$sel:partitionInput:BatchUpdatePartitionRequestEntry' :: BatchUpdatePartitionRequestEntry -> PartitionInput
partitionInput} -> PartitionInput
partitionInput) (\s :: BatchUpdatePartitionRequestEntry
s@BatchUpdatePartitionRequestEntry' {} PartitionInput
a -> BatchUpdatePartitionRequestEntry
s {$sel:partitionInput:BatchUpdatePartitionRequestEntry' :: PartitionInput
partitionInput = PartitionInput
a} :: BatchUpdatePartitionRequestEntry)
instance
Prelude.Hashable
BatchUpdatePartitionRequestEntry
where
hashWithSalt :: Int -> BatchUpdatePartitionRequestEntry -> Int
hashWithSalt
Int
_salt
BatchUpdatePartitionRequestEntry' {[Text]
PartitionInput
partitionInput :: PartitionInput
partitionValueList :: [Text]
$sel:partitionInput:BatchUpdatePartitionRequestEntry' :: BatchUpdatePartitionRequestEntry -> PartitionInput
$sel:partitionValueList:BatchUpdatePartitionRequestEntry' :: BatchUpdatePartitionRequestEntry -> [Text]
..} =
Int
_salt
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` [Text]
partitionValueList
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` PartitionInput
partitionInput
instance
Prelude.NFData
BatchUpdatePartitionRequestEntry
where
rnf :: BatchUpdatePartitionRequestEntry -> ()
rnf BatchUpdatePartitionRequestEntry' {[Text]
PartitionInput
partitionInput :: PartitionInput
partitionValueList :: [Text]
$sel:partitionInput:BatchUpdatePartitionRequestEntry' :: BatchUpdatePartitionRequestEntry -> PartitionInput
$sel:partitionValueList:BatchUpdatePartitionRequestEntry' :: BatchUpdatePartitionRequestEntry -> [Text]
..} =
forall a. NFData a => a -> ()
Prelude.rnf [Text]
partitionValueList
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf PartitionInput
partitionInput
instance Data.ToJSON BatchUpdatePartitionRequestEntry where
toJSON :: BatchUpdatePartitionRequestEntry -> Value
toJSON BatchUpdatePartitionRequestEntry' {[Text]
PartitionInput
partitionInput :: PartitionInput
partitionValueList :: [Text]
$sel:partitionInput:BatchUpdatePartitionRequestEntry' :: BatchUpdatePartitionRequestEntry -> PartitionInput
$sel:partitionValueList:BatchUpdatePartitionRequestEntry' :: BatchUpdatePartitionRequestEntry -> [Text]
..} =
[Pair] -> Value
Data.object
( forall a. [Maybe a] -> [a]
Prelude.catMaybes
[ forall a. a -> Maybe a
Prelude.Just
(Key
"PartitionValueList" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..= [Text]
partitionValueList),
forall a. a -> Maybe a
Prelude.Just
(Key
"PartitionInput" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..= PartitionInput
partitionInput)
]
)