{-# 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.PinpointSMSVoice.Types.CallInstructionsMessageType 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 CallInstructionsMessageType = CallInstructionsMessageType'
{
CallInstructionsMessageType -> Maybe Text
text :: Prelude.Maybe Prelude.Text
}
deriving (CallInstructionsMessageType -> CallInstructionsMessageType -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: CallInstructionsMessageType -> CallInstructionsMessageType -> Bool
$c/= :: CallInstructionsMessageType -> CallInstructionsMessageType -> Bool
== :: CallInstructionsMessageType -> CallInstructionsMessageType -> Bool
$c== :: CallInstructionsMessageType -> CallInstructionsMessageType -> Bool
Prelude.Eq, ReadPrec [CallInstructionsMessageType]
ReadPrec CallInstructionsMessageType
Int -> ReadS CallInstructionsMessageType
ReadS [CallInstructionsMessageType]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [CallInstructionsMessageType]
$creadListPrec :: ReadPrec [CallInstructionsMessageType]
readPrec :: ReadPrec CallInstructionsMessageType
$creadPrec :: ReadPrec CallInstructionsMessageType
readList :: ReadS [CallInstructionsMessageType]
$creadList :: ReadS [CallInstructionsMessageType]
readsPrec :: Int -> ReadS CallInstructionsMessageType
$creadsPrec :: Int -> ReadS CallInstructionsMessageType
Prelude.Read, Int -> CallInstructionsMessageType -> ShowS
[CallInstructionsMessageType] -> ShowS
CallInstructionsMessageType -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [CallInstructionsMessageType] -> ShowS
$cshowList :: [CallInstructionsMessageType] -> ShowS
show :: CallInstructionsMessageType -> String
$cshow :: CallInstructionsMessageType -> String
showsPrec :: Int -> CallInstructionsMessageType -> ShowS
$cshowsPrec :: Int -> CallInstructionsMessageType -> ShowS
Prelude.Show, forall x.
Rep CallInstructionsMessageType x -> CallInstructionsMessageType
forall x.
CallInstructionsMessageType -> Rep CallInstructionsMessageType x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep CallInstructionsMessageType x -> CallInstructionsMessageType
$cfrom :: forall x.
CallInstructionsMessageType -> Rep CallInstructionsMessageType x
Prelude.Generic)
newCallInstructionsMessageType ::
CallInstructionsMessageType
newCallInstructionsMessageType :: CallInstructionsMessageType
newCallInstructionsMessageType =
CallInstructionsMessageType'
{ $sel:text:CallInstructionsMessageType' :: Maybe Text
text =
forall a. Maybe a
Prelude.Nothing
}
callInstructionsMessageType_text :: Lens.Lens' CallInstructionsMessageType (Prelude.Maybe Prelude.Text)
callInstructionsMessageType_text :: Lens' CallInstructionsMessageType (Maybe Text)
callInstructionsMessageType_text = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CallInstructionsMessageType' {Maybe Text
text :: Maybe Text
$sel:text:CallInstructionsMessageType' :: CallInstructionsMessageType -> Maybe Text
text} -> Maybe Text
text) (\s :: CallInstructionsMessageType
s@CallInstructionsMessageType' {} Maybe Text
a -> CallInstructionsMessageType
s {$sel:text:CallInstructionsMessageType' :: Maybe Text
text = Maybe Text
a} :: CallInstructionsMessageType)
instance Prelude.Hashable CallInstructionsMessageType where
hashWithSalt :: Int -> CallInstructionsMessageType -> Int
hashWithSalt Int
_salt CallInstructionsMessageType' {Maybe Text
text :: Maybe Text
$sel:text:CallInstructionsMessageType' :: CallInstructionsMessageType -> Maybe Text
..} =
Int
_salt forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
text
instance Prelude.NFData CallInstructionsMessageType where
rnf :: CallInstructionsMessageType -> ()
rnf CallInstructionsMessageType' {Maybe Text
text :: Maybe Text
$sel:text:CallInstructionsMessageType' :: CallInstructionsMessageType -> Maybe Text
..} =
forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
text
instance Data.ToJSON CallInstructionsMessageType where
toJSON :: CallInstructionsMessageType -> Value
toJSON CallInstructionsMessageType' {Maybe Text
text :: Maybe Text
$sel:text:CallInstructionsMessageType' :: CallInstructionsMessageType -> Maybe Text
..} =
[Pair] -> Value
Data.object
( forall a. [Maybe a] -> [a]
Prelude.catMaybes
[(Key
"Text" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
text]
)