{-# 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.WellArchitected.Types.ShareInvitation 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
import Amazonka.WellArchitected.Types.ShareResourceType
data ShareInvitation = ShareInvitation'
{ ShareInvitation -> Maybe Text
lensAlias :: Prelude.Maybe Prelude.Text,
ShareInvitation -> Maybe Text
lensArn :: Prelude.Maybe Prelude.Text,
ShareInvitation -> Maybe Text
shareInvitationId :: Prelude.Maybe Prelude.Text,
ShareInvitation -> Maybe ShareResourceType
shareResourceType :: Prelude.Maybe ShareResourceType,
ShareInvitation -> Maybe Text
workloadId :: Prelude.Maybe Prelude.Text
}
deriving (ShareInvitation -> ShareInvitation -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ShareInvitation -> ShareInvitation -> Bool
$c/= :: ShareInvitation -> ShareInvitation -> Bool
== :: ShareInvitation -> ShareInvitation -> Bool
$c== :: ShareInvitation -> ShareInvitation -> Bool
Prelude.Eq, ReadPrec [ShareInvitation]
ReadPrec ShareInvitation
Int -> ReadS ShareInvitation
ReadS [ShareInvitation]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ShareInvitation]
$creadListPrec :: ReadPrec [ShareInvitation]
readPrec :: ReadPrec ShareInvitation
$creadPrec :: ReadPrec ShareInvitation
readList :: ReadS [ShareInvitation]
$creadList :: ReadS [ShareInvitation]
readsPrec :: Int -> ReadS ShareInvitation
$creadsPrec :: Int -> ReadS ShareInvitation
Prelude.Read, Int -> ShareInvitation -> ShowS
[ShareInvitation] -> ShowS
ShareInvitation -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ShareInvitation] -> ShowS
$cshowList :: [ShareInvitation] -> ShowS
show :: ShareInvitation -> String
$cshow :: ShareInvitation -> String
showsPrec :: Int -> ShareInvitation -> ShowS
$cshowsPrec :: Int -> ShareInvitation -> ShowS
Prelude.Show, forall x. Rep ShareInvitation x -> ShareInvitation
forall x. ShareInvitation -> Rep ShareInvitation x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep ShareInvitation x -> ShareInvitation
$cfrom :: forall x. ShareInvitation -> Rep ShareInvitation x
Prelude.Generic)
newShareInvitation ::
ShareInvitation
newShareInvitation :: ShareInvitation
newShareInvitation =
ShareInvitation'
{ $sel:lensAlias:ShareInvitation' :: Maybe Text
lensAlias = forall a. Maybe a
Prelude.Nothing,
$sel:lensArn:ShareInvitation' :: Maybe Text
lensArn = forall a. Maybe a
Prelude.Nothing,
$sel:shareInvitationId:ShareInvitation' :: Maybe Text
shareInvitationId = forall a. Maybe a
Prelude.Nothing,
$sel:shareResourceType:ShareInvitation' :: Maybe ShareResourceType
shareResourceType = forall a. Maybe a
Prelude.Nothing,
$sel:workloadId:ShareInvitation' :: Maybe Text
workloadId = forall a. Maybe a
Prelude.Nothing
}
shareInvitation_lensAlias :: Lens.Lens' ShareInvitation (Prelude.Maybe Prelude.Text)
shareInvitation_lensAlias :: Lens' ShareInvitation (Maybe Text)
shareInvitation_lensAlias = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ShareInvitation' {Maybe Text
lensAlias :: Maybe Text
$sel:lensAlias:ShareInvitation' :: ShareInvitation -> Maybe Text
lensAlias} -> Maybe Text
lensAlias) (\s :: ShareInvitation
s@ShareInvitation' {} Maybe Text
a -> ShareInvitation
s {$sel:lensAlias:ShareInvitation' :: Maybe Text
lensAlias = Maybe Text
a} :: ShareInvitation)
shareInvitation_lensArn :: Lens.Lens' ShareInvitation (Prelude.Maybe Prelude.Text)
shareInvitation_lensArn :: Lens' ShareInvitation (Maybe Text)
shareInvitation_lensArn = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ShareInvitation' {Maybe Text
lensArn :: Maybe Text
$sel:lensArn:ShareInvitation' :: ShareInvitation -> Maybe Text
lensArn} -> Maybe Text
lensArn) (\s :: ShareInvitation
s@ShareInvitation' {} Maybe Text
a -> ShareInvitation
s {$sel:lensArn:ShareInvitation' :: Maybe Text
lensArn = Maybe Text
a} :: ShareInvitation)
shareInvitation_shareInvitationId :: Lens.Lens' ShareInvitation (Prelude.Maybe Prelude.Text)
shareInvitation_shareInvitationId :: Lens' ShareInvitation (Maybe Text)
shareInvitation_shareInvitationId = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ShareInvitation' {Maybe Text
shareInvitationId :: Maybe Text
$sel:shareInvitationId:ShareInvitation' :: ShareInvitation -> Maybe Text
shareInvitationId} -> Maybe Text
shareInvitationId) (\s :: ShareInvitation
s@ShareInvitation' {} Maybe Text
a -> ShareInvitation
s {$sel:shareInvitationId:ShareInvitation' :: Maybe Text
shareInvitationId = Maybe Text
a} :: ShareInvitation)
shareInvitation_shareResourceType :: Lens.Lens' ShareInvitation (Prelude.Maybe ShareResourceType)
shareInvitation_shareResourceType :: Lens' ShareInvitation (Maybe ShareResourceType)
shareInvitation_shareResourceType = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ShareInvitation' {Maybe ShareResourceType
shareResourceType :: Maybe ShareResourceType
$sel:shareResourceType:ShareInvitation' :: ShareInvitation -> Maybe ShareResourceType
shareResourceType} -> Maybe ShareResourceType
shareResourceType) (\s :: ShareInvitation
s@ShareInvitation' {} Maybe ShareResourceType
a -> ShareInvitation
s {$sel:shareResourceType:ShareInvitation' :: Maybe ShareResourceType
shareResourceType = Maybe ShareResourceType
a} :: ShareInvitation)
shareInvitation_workloadId :: Lens.Lens' ShareInvitation (Prelude.Maybe Prelude.Text)
shareInvitation_workloadId :: Lens' ShareInvitation (Maybe Text)
shareInvitation_workloadId = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ShareInvitation' {Maybe Text
workloadId :: Maybe Text
$sel:workloadId:ShareInvitation' :: ShareInvitation -> Maybe Text
workloadId} -> Maybe Text
workloadId) (\s :: ShareInvitation
s@ShareInvitation' {} Maybe Text
a -> ShareInvitation
s {$sel:workloadId:ShareInvitation' :: Maybe Text
workloadId = Maybe Text
a} :: ShareInvitation)
instance Data.FromJSON ShareInvitation where
parseJSON :: Value -> Parser ShareInvitation
parseJSON =
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.withObject
String
"ShareInvitation"
( \Object
x ->
Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe ShareResourceType
-> Maybe Text
-> ShareInvitation
ShareInvitation'
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
"LensAlias")
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
"LensArn")
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
"ShareInvitationId")
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
"ShareResourceType")
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
"WorkloadId")
)
instance Prelude.Hashable ShareInvitation where
hashWithSalt :: Int -> ShareInvitation -> Int
hashWithSalt Int
_salt ShareInvitation' {Maybe Text
Maybe ShareResourceType
workloadId :: Maybe Text
shareResourceType :: Maybe ShareResourceType
shareInvitationId :: Maybe Text
lensArn :: Maybe Text
lensAlias :: Maybe Text
$sel:workloadId:ShareInvitation' :: ShareInvitation -> Maybe Text
$sel:shareResourceType:ShareInvitation' :: ShareInvitation -> Maybe ShareResourceType
$sel:shareInvitationId:ShareInvitation' :: ShareInvitation -> Maybe Text
$sel:lensArn:ShareInvitation' :: ShareInvitation -> Maybe Text
$sel:lensAlias:ShareInvitation' :: ShareInvitation -> Maybe Text
..} =
Int
_salt
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
lensAlias
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
lensArn
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
shareInvitationId
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe ShareResourceType
shareResourceType
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
workloadId
instance Prelude.NFData ShareInvitation where
rnf :: ShareInvitation -> ()
rnf ShareInvitation' {Maybe Text
Maybe ShareResourceType
workloadId :: Maybe Text
shareResourceType :: Maybe ShareResourceType
shareInvitationId :: Maybe Text
lensArn :: Maybe Text
lensAlias :: Maybe Text
$sel:workloadId:ShareInvitation' :: ShareInvitation -> Maybe Text
$sel:shareResourceType:ShareInvitation' :: ShareInvitation -> Maybe ShareResourceType
$sel:shareInvitationId:ShareInvitation' :: ShareInvitation -> Maybe Text
$sel:lensArn:ShareInvitation' :: ShareInvitation -> Maybe Text
$sel:lensAlias:ShareInvitation' :: ShareInvitation -> Maybe Text
..} =
forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
lensAlias
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
lensArn
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
shareInvitationId
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe ShareResourceType
shareResourceType
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
workloadId