{-# 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.Route53AutoNaming.Types.HttpNamespaceChange where
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
data HttpNamespaceChange = HttpNamespaceChange'
{
HttpNamespaceChange -> Text
description :: Prelude.Text
}
deriving (HttpNamespaceChange -> HttpNamespaceChange -> Bool
(HttpNamespaceChange -> HttpNamespaceChange -> Bool)
-> (HttpNamespaceChange -> HttpNamespaceChange -> Bool)
-> Eq HttpNamespaceChange
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: HttpNamespaceChange -> HttpNamespaceChange -> Bool
$c/= :: HttpNamespaceChange -> HttpNamespaceChange -> Bool
== :: HttpNamespaceChange -> HttpNamespaceChange -> Bool
$c== :: HttpNamespaceChange -> HttpNamespaceChange -> Bool
Prelude.Eq, ReadPrec [HttpNamespaceChange]
ReadPrec HttpNamespaceChange
Int -> ReadS HttpNamespaceChange
ReadS [HttpNamespaceChange]
(Int -> ReadS HttpNamespaceChange)
-> ReadS [HttpNamespaceChange]
-> ReadPrec HttpNamespaceChange
-> ReadPrec [HttpNamespaceChange]
-> Read HttpNamespaceChange
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [HttpNamespaceChange]
$creadListPrec :: ReadPrec [HttpNamespaceChange]
readPrec :: ReadPrec HttpNamespaceChange
$creadPrec :: ReadPrec HttpNamespaceChange
readList :: ReadS [HttpNamespaceChange]
$creadList :: ReadS [HttpNamespaceChange]
readsPrec :: Int -> ReadS HttpNamespaceChange
$creadsPrec :: Int -> ReadS HttpNamespaceChange
Prelude.Read, Int -> HttpNamespaceChange -> ShowS
[HttpNamespaceChange] -> ShowS
HttpNamespaceChange -> String
(Int -> HttpNamespaceChange -> ShowS)
-> (HttpNamespaceChange -> String)
-> ([HttpNamespaceChange] -> ShowS)
-> Show HttpNamespaceChange
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [HttpNamespaceChange] -> ShowS
$cshowList :: [HttpNamespaceChange] -> ShowS
show :: HttpNamespaceChange -> String
$cshow :: HttpNamespaceChange -> String
showsPrec :: Int -> HttpNamespaceChange -> ShowS
$cshowsPrec :: Int -> HttpNamespaceChange -> ShowS
Prelude.Show, (forall x. HttpNamespaceChange -> Rep HttpNamespaceChange x)
-> (forall x. Rep HttpNamespaceChange x -> HttpNamespaceChange)
-> Generic HttpNamespaceChange
forall x. Rep HttpNamespaceChange x -> HttpNamespaceChange
forall x. HttpNamespaceChange -> Rep HttpNamespaceChange x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep HttpNamespaceChange x -> HttpNamespaceChange
$cfrom :: forall x. HttpNamespaceChange -> Rep HttpNamespaceChange x
Prelude.Generic)
newHttpNamespaceChange ::
Prelude.Text ->
HttpNamespaceChange
newHttpNamespaceChange :: Text -> HttpNamespaceChange
newHttpNamespaceChange Text
pDescription_ =
HttpNamespaceChange' :: Text -> HttpNamespaceChange
HttpNamespaceChange' {$sel:description:HttpNamespaceChange' :: Text
description = Text
pDescription_}
httpNamespaceChange_description :: Lens.Lens' HttpNamespaceChange Prelude.Text
httpNamespaceChange_description :: (Text -> f Text) -> HttpNamespaceChange -> f HttpNamespaceChange
httpNamespaceChange_description = (HttpNamespaceChange -> Text)
-> (HttpNamespaceChange -> Text -> HttpNamespaceChange)
-> Lens HttpNamespaceChange HttpNamespaceChange Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\HttpNamespaceChange' {Text
description :: Text
$sel:description:HttpNamespaceChange' :: HttpNamespaceChange -> Text
description} -> Text
description) (\s :: HttpNamespaceChange
s@HttpNamespaceChange' {} Text
a -> HttpNamespaceChange
s {$sel:description:HttpNamespaceChange' :: Text
description = Text
a} :: HttpNamespaceChange)
instance Prelude.Hashable HttpNamespaceChange
instance Prelude.NFData HttpNamespaceChange
instance Core.ToJSON HttpNamespaceChange where
toJSON :: HttpNamespaceChange -> Value
toJSON HttpNamespaceChange' {Text
description :: Text
$sel:description:HttpNamespaceChange' :: HttpNamespaceChange -> Text
..} =
[Pair] -> Value
Core.object
( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"Description" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
description)]
)