{-# 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.ElasticSearch.Types.EBSOptionsStatus where
import qualified Amazonka.Core as Core
import qualified Amazonka.Core.Lens.Internal as Lens
import qualified Amazonka.Data as Data
import Amazonka.ElasticSearch.Types.EBSOptions
import Amazonka.ElasticSearch.Types.OptionStatus
import qualified Amazonka.Prelude as Prelude
data EBSOptionsStatus = EBSOptionsStatus'
{
EBSOptionsStatus -> EBSOptions
options :: EBSOptions,
EBSOptionsStatus -> OptionStatus
status :: OptionStatus
}
deriving (EBSOptionsStatus -> EBSOptionsStatus -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: EBSOptionsStatus -> EBSOptionsStatus -> Bool
$c/= :: EBSOptionsStatus -> EBSOptionsStatus -> Bool
== :: EBSOptionsStatus -> EBSOptionsStatus -> Bool
$c== :: EBSOptionsStatus -> EBSOptionsStatus -> Bool
Prelude.Eq, ReadPrec [EBSOptionsStatus]
ReadPrec EBSOptionsStatus
Int -> ReadS EBSOptionsStatus
ReadS [EBSOptionsStatus]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [EBSOptionsStatus]
$creadListPrec :: ReadPrec [EBSOptionsStatus]
readPrec :: ReadPrec EBSOptionsStatus
$creadPrec :: ReadPrec EBSOptionsStatus
readList :: ReadS [EBSOptionsStatus]
$creadList :: ReadS [EBSOptionsStatus]
readsPrec :: Int -> ReadS EBSOptionsStatus
$creadsPrec :: Int -> ReadS EBSOptionsStatus
Prelude.Read, Int -> EBSOptionsStatus -> ShowS
[EBSOptionsStatus] -> ShowS
EBSOptionsStatus -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [EBSOptionsStatus] -> ShowS
$cshowList :: [EBSOptionsStatus] -> ShowS
show :: EBSOptionsStatus -> String
$cshow :: EBSOptionsStatus -> String
showsPrec :: Int -> EBSOptionsStatus -> ShowS
$cshowsPrec :: Int -> EBSOptionsStatus -> ShowS
Prelude.Show, forall x. Rep EBSOptionsStatus x -> EBSOptionsStatus
forall x. EBSOptionsStatus -> Rep EBSOptionsStatus x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep EBSOptionsStatus x -> EBSOptionsStatus
$cfrom :: forall x. EBSOptionsStatus -> Rep EBSOptionsStatus x
Prelude.Generic)
newEBSOptionsStatus ::
EBSOptions ->
OptionStatus ->
EBSOptionsStatus
newEBSOptionsStatus :: EBSOptions -> OptionStatus -> EBSOptionsStatus
newEBSOptionsStatus EBSOptions
pOptions_ OptionStatus
pStatus_ =
EBSOptionsStatus'
{ $sel:options:EBSOptionsStatus' :: EBSOptions
options = EBSOptions
pOptions_,
$sel:status:EBSOptionsStatus' :: OptionStatus
status = OptionStatus
pStatus_
}
eBSOptionsStatus_options :: Lens.Lens' EBSOptionsStatus EBSOptions
eBSOptionsStatus_options :: Lens' EBSOptionsStatus EBSOptions
eBSOptionsStatus_options = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\EBSOptionsStatus' {EBSOptions
options :: EBSOptions
$sel:options:EBSOptionsStatus' :: EBSOptionsStatus -> EBSOptions
options} -> EBSOptions
options) (\s :: EBSOptionsStatus
s@EBSOptionsStatus' {} EBSOptions
a -> EBSOptionsStatus
s {$sel:options:EBSOptionsStatus' :: EBSOptions
options = EBSOptions
a} :: EBSOptionsStatus)
eBSOptionsStatus_status :: Lens.Lens' EBSOptionsStatus OptionStatus
eBSOptionsStatus_status :: Lens' EBSOptionsStatus OptionStatus
eBSOptionsStatus_status = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\EBSOptionsStatus' {OptionStatus
status :: OptionStatus
$sel:status:EBSOptionsStatus' :: EBSOptionsStatus -> OptionStatus
status} -> OptionStatus
status) (\s :: EBSOptionsStatus
s@EBSOptionsStatus' {} OptionStatus
a -> EBSOptionsStatus
s {$sel:status:EBSOptionsStatus' :: OptionStatus
status = OptionStatus
a} :: EBSOptionsStatus)
instance Data.FromJSON EBSOptionsStatus where
parseJSON :: Value -> Parser EBSOptionsStatus
parseJSON =
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.withObject
String
"EBSOptionsStatus"
( \Object
x ->
EBSOptions -> OptionStatus -> EBSOptionsStatus
EBSOptionsStatus'
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
"Options")
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
"Status")
)
instance Prelude.Hashable EBSOptionsStatus where
hashWithSalt :: Int -> EBSOptionsStatus -> Int
hashWithSalt Int
_salt EBSOptionsStatus' {OptionStatus
EBSOptions
status :: OptionStatus
options :: EBSOptions
$sel:status:EBSOptionsStatus' :: EBSOptionsStatus -> OptionStatus
$sel:options:EBSOptionsStatus' :: EBSOptionsStatus -> EBSOptions
..} =
Int
_salt
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` EBSOptions
options
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` OptionStatus
status
instance Prelude.NFData EBSOptionsStatus where
rnf :: EBSOptionsStatus -> ()
rnf EBSOptionsStatus' {OptionStatus
EBSOptions
status :: OptionStatus
options :: EBSOptions
$sel:status:EBSOptionsStatus' :: EBSOptionsStatus -> OptionStatus
$sel:options:EBSOptionsStatus' :: EBSOptionsStatus -> EBSOptions
..} =
forall a. NFData a => a -> ()
Prelude.rnf EBSOptions
options
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf OptionStatus
status