{-# 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.ListPhoneNumbersSummary where
import Amazonka.Connect.Types.PhoneNumberCountryCode
import Amazonka.Connect.Types.PhoneNumberType
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 =
{
:: Prelude.Maybe Prelude.Text,
:: Prelude.Maybe Prelude.Text,
:: Prelude.Maybe PhoneNumberCountryCode,
:: Prelude.Maybe Prelude.Text,
:: Prelude.Maybe PhoneNumberType,
:: Prelude.Maybe Prelude.Text
}
deriving (ListPhoneNumbersSummary -> ListPhoneNumbersSummary -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ListPhoneNumbersSummary -> ListPhoneNumbersSummary -> Bool
$c/= :: ListPhoneNumbersSummary -> ListPhoneNumbersSummary -> Bool
== :: ListPhoneNumbersSummary -> ListPhoneNumbersSummary -> Bool
$c== :: ListPhoneNumbersSummary -> ListPhoneNumbersSummary -> Bool
Prelude.Eq, ReadPrec [ListPhoneNumbersSummary]
ReadPrec ListPhoneNumbersSummary
Int -> ReadS ListPhoneNumbersSummary
ReadS [ListPhoneNumbersSummary]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ListPhoneNumbersSummary]
$creadListPrec :: ReadPrec [ListPhoneNumbersSummary]
readPrec :: ReadPrec ListPhoneNumbersSummary
$creadPrec :: ReadPrec ListPhoneNumbersSummary
readList :: ReadS [ListPhoneNumbersSummary]
$creadList :: ReadS [ListPhoneNumbersSummary]
readsPrec :: Int -> ReadS ListPhoneNumbersSummary
$creadsPrec :: Int -> ReadS ListPhoneNumbersSummary
Prelude.Read, Int -> ListPhoneNumbersSummary -> ShowS
[ListPhoneNumbersSummary] -> ShowS
ListPhoneNumbersSummary -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ListPhoneNumbersSummary] -> ShowS
$cshowList :: [ListPhoneNumbersSummary] -> ShowS
show :: ListPhoneNumbersSummary -> String
$cshow :: ListPhoneNumbersSummary -> String
showsPrec :: Int -> ListPhoneNumbersSummary -> ShowS
$cshowsPrec :: Int -> ListPhoneNumbersSummary -> ShowS
Prelude.Show, forall x. Rep ListPhoneNumbersSummary x -> ListPhoneNumbersSummary
forall x. ListPhoneNumbersSummary -> Rep ListPhoneNumbersSummary x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep ListPhoneNumbersSummary x -> ListPhoneNumbersSummary
$cfrom :: forall x. ListPhoneNumbersSummary -> Rep ListPhoneNumbersSummary x
Prelude.Generic)
newListPhoneNumbersSummary ::
ListPhoneNumbersSummary
=
ListPhoneNumbersSummary'
{ $sel:phoneNumber:ListPhoneNumbersSummary' :: Maybe Text
phoneNumber =
forall a. Maybe a
Prelude.Nothing,
$sel:phoneNumberArn:ListPhoneNumbersSummary' :: Maybe Text
phoneNumberArn = forall a. Maybe a
Prelude.Nothing,
$sel:phoneNumberCountryCode:ListPhoneNumbersSummary' :: Maybe PhoneNumberCountryCode
phoneNumberCountryCode = forall a. Maybe a
Prelude.Nothing,
$sel:phoneNumberId:ListPhoneNumbersSummary' :: Maybe Text
phoneNumberId = forall a. Maybe a
Prelude.Nothing,
$sel:phoneNumberType:ListPhoneNumbersSummary' :: Maybe PhoneNumberType
phoneNumberType = forall a. Maybe a
Prelude.Nothing,
$sel:targetArn:ListPhoneNumbersSummary' :: Maybe Text
targetArn = forall a. Maybe a
Prelude.Nothing
}
listPhoneNumbersSummary_phoneNumber :: Lens.Lens' ListPhoneNumbersSummary (Prelude.Maybe Prelude.Text)
= forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListPhoneNumbersSummary' {Maybe Text
phoneNumber :: Maybe Text
$sel:phoneNumber:ListPhoneNumbersSummary' :: ListPhoneNumbersSummary -> Maybe Text
phoneNumber} -> Maybe Text
phoneNumber) (\s :: ListPhoneNumbersSummary
s@ListPhoneNumbersSummary' {} Maybe Text
a -> ListPhoneNumbersSummary
s {$sel:phoneNumber:ListPhoneNumbersSummary' :: Maybe Text
phoneNumber = Maybe Text
a} :: ListPhoneNumbersSummary)
listPhoneNumbersSummary_phoneNumberArn :: Lens.Lens' ListPhoneNumbersSummary (Prelude.Maybe Prelude.Text)
= forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListPhoneNumbersSummary' {Maybe Text
phoneNumberArn :: Maybe Text
$sel:phoneNumberArn:ListPhoneNumbersSummary' :: ListPhoneNumbersSummary -> Maybe Text
phoneNumberArn} -> Maybe Text
phoneNumberArn) (\s :: ListPhoneNumbersSummary
s@ListPhoneNumbersSummary' {} Maybe Text
a -> ListPhoneNumbersSummary
s {$sel:phoneNumberArn:ListPhoneNumbersSummary' :: Maybe Text
phoneNumberArn = Maybe Text
a} :: ListPhoneNumbersSummary)
listPhoneNumbersSummary_phoneNumberCountryCode :: Lens.Lens' ListPhoneNumbersSummary (Prelude.Maybe PhoneNumberCountryCode)
= forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListPhoneNumbersSummary' {Maybe PhoneNumberCountryCode
phoneNumberCountryCode :: Maybe PhoneNumberCountryCode
$sel:phoneNumberCountryCode:ListPhoneNumbersSummary' :: ListPhoneNumbersSummary -> Maybe PhoneNumberCountryCode
phoneNumberCountryCode} -> Maybe PhoneNumberCountryCode
phoneNumberCountryCode) (\s :: ListPhoneNumbersSummary
s@ListPhoneNumbersSummary' {} Maybe PhoneNumberCountryCode
a -> ListPhoneNumbersSummary
s {$sel:phoneNumberCountryCode:ListPhoneNumbersSummary' :: Maybe PhoneNumberCountryCode
phoneNumberCountryCode = Maybe PhoneNumberCountryCode
a} :: ListPhoneNumbersSummary)
listPhoneNumbersSummary_phoneNumberId :: Lens.Lens' ListPhoneNumbersSummary (Prelude.Maybe Prelude.Text)
= forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListPhoneNumbersSummary' {Maybe Text
phoneNumberId :: Maybe Text
$sel:phoneNumberId:ListPhoneNumbersSummary' :: ListPhoneNumbersSummary -> Maybe Text
phoneNumberId} -> Maybe Text
phoneNumberId) (\s :: ListPhoneNumbersSummary
s@ListPhoneNumbersSummary' {} Maybe Text
a -> ListPhoneNumbersSummary
s {$sel:phoneNumberId:ListPhoneNumbersSummary' :: Maybe Text
phoneNumberId = Maybe Text
a} :: ListPhoneNumbersSummary)
listPhoneNumbersSummary_phoneNumberType :: Lens.Lens' ListPhoneNumbersSummary (Prelude.Maybe PhoneNumberType)
= forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListPhoneNumbersSummary' {Maybe PhoneNumberType
phoneNumberType :: Maybe PhoneNumberType
$sel:phoneNumberType:ListPhoneNumbersSummary' :: ListPhoneNumbersSummary -> Maybe PhoneNumberType
phoneNumberType} -> Maybe PhoneNumberType
phoneNumberType) (\s :: ListPhoneNumbersSummary
s@ListPhoneNumbersSummary' {} Maybe PhoneNumberType
a -> ListPhoneNumbersSummary
s {$sel:phoneNumberType:ListPhoneNumbersSummary' :: Maybe PhoneNumberType
phoneNumberType = Maybe PhoneNumberType
a} :: ListPhoneNumbersSummary)
listPhoneNumbersSummary_targetArn :: Lens.Lens' ListPhoneNumbersSummary (Prelude.Maybe Prelude.Text)
= forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListPhoneNumbersSummary' {Maybe Text
targetArn :: Maybe Text
$sel:targetArn:ListPhoneNumbersSummary' :: ListPhoneNumbersSummary -> Maybe Text
targetArn} -> Maybe Text
targetArn) (\s :: ListPhoneNumbersSummary
s@ListPhoneNumbersSummary' {} Maybe Text
a -> ListPhoneNumbersSummary
s {$sel:targetArn:ListPhoneNumbersSummary' :: Maybe Text
targetArn = Maybe Text
a} :: ListPhoneNumbersSummary)
instance Data.FromJSON ListPhoneNumbersSummary where
parseJSON :: Value -> Parser ListPhoneNumbersSummary
parseJSON =
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.withObject
String
"ListPhoneNumbersSummary"
( \Object
x ->
Maybe Text
-> Maybe Text
-> Maybe PhoneNumberCountryCode
-> Maybe Text
-> Maybe PhoneNumberType
-> Maybe Text
-> ListPhoneNumbersSummary
ListPhoneNumbersSummary'
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"PhoneNumber")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"PhoneNumberArn")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"PhoneNumberCountryCode")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"PhoneNumberId")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"PhoneNumberType")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"TargetArn")
)
instance Prelude.Hashable ListPhoneNumbersSummary where
hashWithSalt :: Int -> ListPhoneNumbersSummary -> Int
hashWithSalt Int
_salt ListPhoneNumbersSummary' {Maybe Text
Maybe PhoneNumberCountryCode
Maybe PhoneNumberType
targetArn :: Maybe Text
phoneNumberType :: Maybe PhoneNumberType
phoneNumberId :: Maybe Text
phoneNumberCountryCode :: Maybe PhoneNumberCountryCode
phoneNumberArn :: Maybe Text
phoneNumber :: Maybe Text
$sel:targetArn:ListPhoneNumbersSummary' :: ListPhoneNumbersSummary -> Maybe Text
$sel:phoneNumberType:ListPhoneNumbersSummary' :: ListPhoneNumbersSummary -> Maybe PhoneNumberType
$sel:phoneNumberId:ListPhoneNumbersSummary' :: ListPhoneNumbersSummary -> Maybe Text
$sel:phoneNumberCountryCode:ListPhoneNumbersSummary' :: ListPhoneNumbersSummary -> Maybe PhoneNumberCountryCode
$sel:phoneNumberArn:ListPhoneNumbersSummary' :: ListPhoneNumbersSummary -> Maybe Text
$sel:phoneNumber:ListPhoneNumbersSummary' :: ListPhoneNumbersSummary -> Maybe Text
..} =
Int
_salt
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
phoneNumber
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
phoneNumberArn
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe PhoneNumberCountryCode
phoneNumberCountryCode
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
phoneNumberId
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe PhoneNumberType
phoneNumberType
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
targetArn
instance Prelude.NFData ListPhoneNumbersSummary where
rnf :: ListPhoneNumbersSummary -> ()
rnf ListPhoneNumbersSummary' {Maybe Text
Maybe PhoneNumberCountryCode
Maybe PhoneNumberType
targetArn :: Maybe Text
phoneNumberType :: Maybe PhoneNumberType
phoneNumberId :: Maybe Text
phoneNumberCountryCode :: Maybe PhoneNumberCountryCode
phoneNumberArn :: Maybe Text
phoneNumber :: Maybe Text
$sel:targetArn:ListPhoneNumbersSummary' :: ListPhoneNumbersSummary -> Maybe Text
$sel:phoneNumberType:ListPhoneNumbersSummary' :: ListPhoneNumbersSummary -> Maybe PhoneNumberType
$sel:phoneNumberId:ListPhoneNumbersSummary' :: ListPhoneNumbersSummary -> Maybe Text
$sel:phoneNumberCountryCode:ListPhoneNumbersSummary' :: ListPhoneNumbersSummary -> Maybe PhoneNumberCountryCode
$sel:phoneNumberArn:ListPhoneNumbersSummary' :: ListPhoneNumbersSummary -> Maybe Text
$sel:phoneNumber:ListPhoneNumbersSummary' :: ListPhoneNumbersSummary -> Maybe Text
..} =
forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
phoneNumber
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
phoneNumberArn
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe PhoneNumberCountryCode
phoneNumberCountryCode
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
phoneNumberId
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe PhoneNumberType
phoneNumberType
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
targetArn