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