{-# 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.Chime.Types.AppInstanceUserSummary where
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
data AppInstanceUserSummary = AppInstanceUserSummary'
{
AppInstanceUserSummary -> Maybe Text
appInstanceUserArn :: Prelude.Maybe Prelude.Text,
AppInstanceUserSummary -> Maybe (Sensitive Text)
name :: Prelude.Maybe (Core.Sensitive Prelude.Text),
AppInstanceUserSummary -> Maybe (Sensitive Text)
metadata :: Prelude.Maybe (Core.Sensitive Prelude.Text)
}
deriving (AppInstanceUserSummary -> AppInstanceUserSummary -> Bool
(AppInstanceUserSummary -> AppInstanceUserSummary -> Bool)
-> (AppInstanceUserSummary -> AppInstanceUserSummary -> Bool)
-> Eq AppInstanceUserSummary
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: AppInstanceUserSummary -> AppInstanceUserSummary -> Bool
$c/= :: AppInstanceUserSummary -> AppInstanceUserSummary -> Bool
== :: AppInstanceUserSummary -> AppInstanceUserSummary -> Bool
$c== :: AppInstanceUserSummary -> AppInstanceUserSummary -> Bool
Prelude.Eq, Int -> AppInstanceUserSummary -> ShowS
[AppInstanceUserSummary] -> ShowS
AppInstanceUserSummary -> String
(Int -> AppInstanceUserSummary -> ShowS)
-> (AppInstanceUserSummary -> String)
-> ([AppInstanceUserSummary] -> ShowS)
-> Show AppInstanceUserSummary
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [AppInstanceUserSummary] -> ShowS
$cshowList :: [AppInstanceUserSummary] -> ShowS
show :: AppInstanceUserSummary -> String
$cshow :: AppInstanceUserSummary -> String
showsPrec :: Int -> AppInstanceUserSummary -> ShowS
$cshowsPrec :: Int -> AppInstanceUserSummary -> ShowS
Prelude.Show, (forall x. AppInstanceUserSummary -> Rep AppInstanceUserSummary x)
-> (forall x.
Rep AppInstanceUserSummary x -> AppInstanceUserSummary)
-> Generic AppInstanceUserSummary
forall x. Rep AppInstanceUserSummary x -> AppInstanceUserSummary
forall x. AppInstanceUserSummary -> Rep AppInstanceUserSummary x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep AppInstanceUserSummary x -> AppInstanceUserSummary
$cfrom :: forall x. AppInstanceUserSummary -> Rep AppInstanceUserSummary x
Prelude.Generic)
newAppInstanceUserSummary ::
AppInstanceUserSummary
newAppInstanceUserSummary :: AppInstanceUserSummary
newAppInstanceUserSummary =
AppInstanceUserSummary' :: Maybe Text
-> Maybe (Sensitive Text)
-> Maybe (Sensitive Text)
-> AppInstanceUserSummary
AppInstanceUserSummary'
{ $sel:appInstanceUserArn:AppInstanceUserSummary' :: Maybe Text
appInstanceUserArn =
Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:name:AppInstanceUserSummary' :: Maybe (Sensitive Text)
name = Maybe (Sensitive Text)
forall a. Maybe a
Prelude.Nothing,
$sel:metadata:AppInstanceUserSummary' :: Maybe (Sensitive Text)
metadata = Maybe (Sensitive Text)
forall a. Maybe a
Prelude.Nothing
}
appInstanceUserSummary_appInstanceUserArn :: Lens.Lens' AppInstanceUserSummary (Prelude.Maybe Prelude.Text)
appInstanceUserSummary_appInstanceUserArn :: (Maybe Text -> f (Maybe Text))
-> AppInstanceUserSummary -> f AppInstanceUserSummary
appInstanceUserSummary_appInstanceUserArn = (AppInstanceUserSummary -> Maybe Text)
-> (AppInstanceUserSummary -> Maybe Text -> AppInstanceUserSummary)
-> Lens
AppInstanceUserSummary
AppInstanceUserSummary
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AppInstanceUserSummary' {Maybe Text
appInstanceUserArn :: Maybe Text
$sel:appInstanceUserArn:AppInstanceUserSummary' :: AppInstanceUserSummary -> Maybe Text
appInstanceUserArn} -> Maybe Text
appInstanceUserArn) (\s :: AppInstanceUserSummary
s@AppInstanceUserSummary' {} Maybe Text
a -> AppInstanceUserSummary
s {$sel:appInstanceUserArn:AppInstanceUserSummary' :: Maybe Text
appInstanceUserArn = Maybe Text
a} :: AppInstanceUserSummary)
appInstanceUserSummary_name :: Lens.Lens' AppInstanceUserSummary (Prelude.Maybe Prelude.Text)
appInstanceUserSummary_name :: (Maybe Text -> f (Maybe Text))
-> AppInstanceUserSummary -> f AppInstanceUserSummary
appInstanceUserSummary_name = (AppInstanceUserSummary -> Maybe (Sensitive Text))
-> (AppInstanceUserSummary
-> Maybe (Sensitive Text) -> AppInstanceUserSummary)
-> Lens
AppInstanceUserSummary
AppInstanceUserSummary
(Maybe (Sensitive Text))
(Maybe (Sensitive Text))
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AppInstanceUserSummary' {Maybe (Sensitive Text)
name :: Maybe (Sensitive Text)
$sel:name:AppInstanceUserSummary' :: AppInstanceUserSummary -> Maybe (Sensitive Text)
name} -> Maybe (Sensitive Text)
name) (\s :: AppInstanceUserSummary
s@AppInstanceUserSummary' {} Maybe (Sensitive Text)
a -> AppInstanceUserSummary
s {$sel:name:AppInstanceUserSummary' :: Maybe (Sensitive Text)
name = Maybe (Sensitive Text)
a} :: AppInstanceUserSummary) ((Maybe (Sensitive Text) -> f (Maybe (Sensitive Text)))
-> AppInstanceUserSummary -> f AppInstanceUserSummary)
-> ((Maybe Text -> f (Maybe Text))
-> Maybe (Sensitive Text) -> f (Maybe (Sensitive Text)))
-> (Maybe Text -> f (Maybe Text))
-> AppInstanceUserSummary
-> f AppInstanceUserSummary
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso (Sensitive Text) (Sensitive Text) Text Text
-> Iso
(Maybe (Sensitive Text))
(Maybe (Sensitive Text))
(Maybe Text)
(Maybe Text)
forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping AnIso (Sensitive Text) (Sensitive Text) Text Text
forall a. Iso' (Sensitive a) a
Core._Sensitive
appInstanceUserSummary_metadata :: Lens.Lens' AppInstanceUserSummary (Prelude.Maybe Prelude.Text)
appInstanceUserSummary_metadata :: (Maybe Text -> f (Maybe Text))
-> AppInstanceUserSummary -> f AppInstanceUserSummary
appInstanceUserSummary_metadata = (AppInstanceUserSummary -> Maybe (Sensitive Text))
-> (AppInstanceUserSummary
-> Maybe (Sensitive Text) -> AppInstanceUserSummary)
-> Lens
AppInstanceUserSummary
AppInstanceUserSummary
(Maybe (Sensitive Text))
(Maybe (Sensitive Text))
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AppInstanceUserSummary' {Maybe (Sensitive Text)
metadata :: Maybe (Sensitive Text)
$sel:metadata:AppInstanceUserSummary' :: AppInstanceUserSummary -> Maybe (Sensitive Text)
metadata} -> Maybe (Sensitive Text)
metadata) (\s :: AppInstanceUserSummary
s@AppInstanceUserSummary' {} Maybe (Sensitive Text)
a -> AppInstanceUserSummary
s {$sel:metadata:AppInstanceUserSummary' :: Maybe (Sensitive Text)
metadata = Maybe (Sensitive Text)
a} :: AppInstanceUserSummary) ((Maybe (Sensitive Text) -> f (Maybe (Sensitive Text)))
-> AppInstanceUserSummary -> f AppInstanceUserSummary)
-> ((Maybe Text -> f (Maybe Text))
-> Maybe (Sensitive Text) -> f (Maybe (Sensitive Text)))
-> (Maybe Text -> f (Maybe Text))
-> AppInstanceUserSummary
-> f AppInstanceUserSummary
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso (Sensitive Text) (Sensitive Text) Text Text
-> Iso
(Maybe (Sensitive Text))
(Maybe (Sensitive Text))
(Maybe Text)
(Maybe Text)
forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping AnIso (Sensitive Text) (Sensitive Text) Text Text
forall a. Iso' (Sensitive a) a
Core._Sensitive
instance Core.FromJSON AppInstanceUserSummary where
parseJSON :: Value -> Parser AppInstanceUserSummary
parseJSON =
String
-> (Object -> Parser AppInstanceUserSummary)
-> Value
-> Parser AppInstanceUserSummary
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
String
"AppInstanceUserSummary"
( \Object
x ->
Maybe Text
-> Maybe (Sensitive Text)
-> Maybe (Sensitive Text)
-> AppInstanceUserSummary
AppInstanceUserSummary'
(Maybe Text
-> Maybe (Sensitive Text)
-> Maybe (Sensitive Text)
-> AppInstanceUserSummary)
-> Parser (Maybe Text)
-> Parser
(Maybe (Sensitive Text)
-> Maybe (Sensitive Text) -> AppInstanceUserSummary)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"AppInstanceUserArn")
Parser
(Maybe (Sensitive Text)
-> Maybe (Sensitive Text) -> AppInstanceUserSummary)
-> Parser (Maybe (Sensitive Text))
-> Parser (Maybe (Sensitive Text) -> AppInstanceUserSummary)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe (Sensitive Text))
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Name")
Parser (Maybe (Sensitive Text) -> AppInstanceUserSummary)
-> Parser (Maybe (Sensitive Text)) -> Parser AppInstanceUserSummary
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe (Sensitive Text))
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Metadata")
)
instance Prelude.Hashable AppInstanceUserSummary
instance Prelude.NFData AppInstanceUserSummary