{-# 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.STS.Types.PolicyDescriptorType 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 PolicyDescriptorType = PolicyDescriptorType'
{
PolicyDescriptorType -> Maybe Text
arn :: Prelude.Maybe Prelude.Text
}
deriving (PolicyDescriptorType -> PolicyDescriptorType -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: PolicyDescriptorType -> PolicyDescriptorType -> Bool
$c/= :: PolicyDescriptorType -> PolicyDescriptorType -> Bool
== :: PolicyDescriptorType -> PolicyDescriptorType -> Bool
$c== :: PolicyDescriptorType -> PolicyDescriptorType -> Bool
Prelude.Eq, ReadPrec [PolicyDescriptorType]
ReadPrec PolicyDescriptorType
Int -> ReadS PolicyDescriptorType
ReadS [PolicyDescriptorType]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [PolicyDescriptorType]
$creadListPrec :: ReadPrec [PolicyDescriptorType]
readPrec :: ReadPrec PolicyDescriptorType
$creadPrec :: ReadPrec PolicyDescriptorType
readList :: ReadS [PolicyDescriptorType]
$creadList :: ReadS [PolicyDescriptorType]
readsPrec :: Int -> ReadS PolicyDescriptorType
$creadsPrec :: Int -> ReadS PolicyDescriptorType
Prelude.Read, Int -> PolicyDescriptorType -> ShowS
[PolicyDescriptorType] -> ShowS
PolicyDescriptorType -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [PolicyDescriptorType] -> ShowS
$cshowList :: [PolicyDescriptorType] -> ShowS
show :: PolicyDescriptorType -> String
$cshow :: PolicyDescriptorType -> String
showsPrec :: Int -> PolicyDescriptorType -> ShowS
$cshowsPrec :: Int -> PolicyDescriptorType -> ShowS
Prelude.Show, forall x. Rep PolicyDescriptorType x -> PolicyDescriptorType
forall x. PolicyDescriptorType -> Rep PolicyDescriptorType x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep PolicyDescriptorType x -> PolicyDescriptorType
$cfrom :: forall x. PolicyDescriptorType -> Rep PolicyDescriptorType x
Prelude.Generic)
newPolicyDescriptorType ::
PolicyDescriptorType
newPolicyDescriptorType :: PolicyDescriptorType
newPolicyDescriptorType =
PolicyDescriptorType' {$sel:arn:PolicyDescriptorType' :: Maybe Text
arn = forall a. Maybe a
Prelude.Nothing}
policyDescriptorType_arn :: Lens.Lens' PolicyDescriptorType (Prelude.Maybe Prelude.Text)
policyDescriptorType_arn :: Lens' PolicyDescriptorType (Maybe Text)
policyDescriptorType_arn = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\PolicyDescriptorType' {Maybe Text
arn :: Maybe Text
$sel:arn:PolicyDescriptorType' :: PolicyDescriptorType -> Maybe Text
arn} -> Maybe Text
arn) (\s :: PolicyDescriptorType
s@PolicyDescriptorType' {} Maybe Text
a -> PolicyDescriptorType
s {$sel:arn:PolicyDescriptorType' :: Maybe Text
arn = Maybe Text
a} :: PolicyDescriptorType)
instance Prelude.Hashable PolicyDescriptorType where
hashWithSalt :: Int -> PolicyDescriptorType -> Int
hashWithSalt Int
_salt PolicyDescriptorType' {Maybe Text
arn :: Maybe Text
$sel:arn:PolicyDescriptorType' :: PolicyDescriptorType -> Maybe Text
..} =
Int
_salt forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
arn
instance Prelude.NFData PolicyDescriptorType where
rnf :: PolicyDescriptorType -> ()
rnf PolicyDescriptorType' {Maybe Text
arn :: Maybe Text
$sel:arn:PolicyDescriptorType' :: PolicyDescriptorType -> Maybe Text
..} = forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
arn
instance Data.ToQuery PolicyDescriptorType where
toQuery :: PolicyDescriptorType -> QueryString
toQuery PolicyDescriptorType' {Maybe Text
arn :: Maybe Text
$sel:arn:PolicyDescriptorType' :: PolicyDescriptorType -> Maybe Text
..} =
forall a. Monoid a => [a] -> a
Prelude.mconcat [ByteString
"arn" forall a. ToQuery a => ByteString -> a -> QueryString
Data.=: Maybe Text
arn]