{-# 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.CloudFormation.Types.PhysicalResourceIdContextKeyValuePair 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 PhysicalResourceIdContextKeyValuePair = PhysicalResourceIdContextKeyValuePair'
{
PhysicalResourceIdContextKeyValuePair -> Text
key :: Prelude.Text,
PhysicalResourceIdContextKeyValuePair -> Text
value :: Prelude.Text
}
deriving (PhysicalResourceIdContextKeyValuePair
-> PhysicalResourceIdContextKeyValuePair -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: PhysicalResourceIdContextKeyValuePair
-> PhysicalResourceIdContextKeyValuePair -> Bool
$c/= :: PhysicalResourceIdContextKeyValuePair
-> PhysicalResourceIdContextKeyValuePair -> Bool
== :: PhysicalResourceIdContextKeyValuePair
-> PhysicalResourceIdContextKeyValuePair -> Bool
$c== :: PhysicalResourceIdContextKeyValuePair
-> PhysicalResourceIdContextKeyValuePair -> Bool
Prelude.Eq, ReadPrec [PhysicalResourceIdContextKeyValuePair]
ReadPrec PhysicalResourceIdContextKeyValuePair
Int -> ReadS PhysicalResourceIdContextKeyValuePair
ReadS [PhysicalResourceIdContextKeyValuePair]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [PhysicalResourceIdContextKeyValuePair]
$creadListPrec :: ReadPrec [PhysicalResourceIdContextKeyValuePair]
readPrec :: ReadPrec PhysicalResourceIdContextKeyValuePair
$creadPrec :: ReadPrec PhysicalResourceIdContextKeyValuePair
readList :: ReadS [PhysicalResourceIdContextKeyValuePair]
$creadList :: ReadS [PhysicalResourceIdContextKeyValuePair]
readsPrec :: Int -> ReadS PhysicalResourceIdContextKeyValuePair
$creadsPrec :: Int -> ReadS PhysicalResourceIdContextKeyValuePair
Prelude.Read, Int -> PhysicalResourceIdContextKeyValuePair -> ShowS
[PhysicalResourceIdContextKeyValuePair] -> ShowS
PhysicalResourceIdContextKeyValuePair -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [PhysicalResourceIdContextKeyValuePair] -> ShowS
$cshowList :: [PhysicalResourceIdContextKeyValuePair] -> ShowS
show :: PhysicalResourceIdContextKeyValuePair -> String
$cshow :: PhysicalResourceIdContextKeyValuePair -> String
showsPrec :: Int -> PhysicalResourceIdContextKeyValuePair -> ShowS
$cshowsPrec :: Int -> PhysicalResourceIdContextKeyValuePair -> ShowS
Prelude.Show, forall x.
Rep PhysicalResourceIdContextKeyValuePair x
-> PhysicalResourceIdContextKeyValuePair
forall x.
PhysicalResourceIdContextKeyValuePair
-> Rep PhysicalResourceIdContextKeyValuePair x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep PhysicalResourceIdContextKeyValuePair x
-> PhysicalResourceIdContextKeyValuePair
$cfrom :: forall x.
PhysicalResourceIdContextKeyValuePair
-> Rep PhysicalResourceIdContextKeyValuePair x
Prelude.Generic)
newPhysicalResourceIdContextKeyValuePair ::
Prelude.Text ->
Prelude.Text ->
PhysicalResourceIdContextKeyValuePair
newPhysicalResourceIdContextKeyValuePair :: Text -> Text -> PhysicalResourceIdContextKeyValuePair
newPhysicalResourceIdContextKeyValuePair
Text
pKey_
Text
pValue_ =
PhysicalResourceIdContextKeyValuePair'
{ $sel:key:PhysicalResourceIdContextKeyValuePair' :: Text
key = Text
pKey_,
$sel:value:PhysicalResourceIdContextKeyValuePair' :: Text
value = Text
pValue_
}
physicalResourceIdContextKeyValuePair_key :: Lens.Lens' PhysicalResourceIdContextKeyValuePair Prelude.Text
physicalResourceIdContextKeyValuePair_key :: Lens' PhysicalResourceIdContextKeyValuePair Text
physicalResourceIdContextKeyValuePair_key = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\PhysicalResourceIdContextKeyValuePair' {Text
key :: Text
$sel:key:PhysicalResourceIdContextKeyValuePair' :: PhysicalResourceIdContextKeyValuePair -> Text
key} -> Text
key) (\s :: PhysicalResourceIdContextKeyValuePair
s@PhysicalResourceIdContextKeyValuePair' {} Text
a -> PhysicalResourceIdContextKeyValuePair
s {$sel:key:PhysicalResourceIdContextKeyValuePair' :: Text
key = Text
a} :: PhysicalResourceIdContextKeyValuePair)
physicalResourceIdContextKeyValuePair_value :: Lens.Lens' PhysicalResourceIdContextKeyValuePair Prelude.Text
physicalResourceIdContextKeyValuePair_value :: Lens' PhysicalResourceIdContextKeyValuePair Text
physicalResourceIdContextKeyValuePair_value = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\PhysicalResourceIdContextKeyValuePair' {Text
value :: Text
$sel:value:PhysicalResourceIdContextKeyValuePair' :: PhysicalResourceIdContextKeyValuePair -> Text
value} -> Text
value) (\s :: PhysicalResourceIdContextKeyValuePair
s@PhysicalResourceIdContextKeyValuePair' {} Text
a -> PhysicalResourceIdContextKeyValuePair
s {$sel:value:PhysicalResourceIdContextKeyValuePair' :: Text
value = Text
a} :: PhysicalResourceIdContextKeyValuePair)
instance
Data.FromXML
PhysicalResourceIdContextKeyValuePair
where
parseXML :: [Node] -> Either String PhysicalResourceIdContextKeyValuePair
parseXML [Node]
x =
Text -> Text -> PhysicalResourceIdContextKeyValuePair
PhysicalResourceIdContextKeyValuePair'
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> ([Node]
x forall a. FromXML a => [Node] -> Text -> Either String a
Data..@ Text
"Key")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x forall a. FromXML a => [Node] -> Text -> Either String a
Data..@ Text
"Value")
instance
Prelude.Hashable
PhysicalResourceIdContextKeyValuePair
where
hashWithSalt :: Int -> PhysicalResourceIdContextKeyValuePair -> Int
hashWithSalt
Int
_salt
PhysicalResourceIdContextKeyValuePair' {Text
value :: Text
key :: Text
$sel:value:PhysicalResourceIdContextKeyValuePair' :: PhysicalResourceIdContextKeyValuePair -> Text
$sel:key:PhysicalResourceIdContextKeyValuePair' :: PhysicalResourceIdContextKeyValuePair -> Text
..} =
Int
_salt
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
key
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
value
instance
Prelude.NFData
PhysicalResourceIdContextKeyValuePair
where
rnf :: PhysicalResourceIdContextKeyValuePair -> ()
rnf PhysicalResourceIdContextKeyValuePair' {Text
value :: Text
key :: Text
$sel:value:PhysicalResourceIdContextKeyValuePair' :: PhysicalResourceIdContextKeyValuePair -> Text
$sel:key:PhysicalResourceIdContextKeyValuePair' :: PhysicalResourceIdContextKeyValuePair -> Text
..} =
forall a. NFData a => a -> ()
Prelude.rnf Text
key seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
value