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