{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE DuplicateRecordFields #-}
{-# LANGUAGE NamedFieldPuns #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-binds #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}
module Amazonka.LakeFormation.ListPermissions
(
ListPermissions (..),
newListPermissions,
listPermissions_resourceType,
listPermissions_catalogId,
listPermissions_nextToken,
listPermissions_principal,
listPermissions_resource,
listPermissions_maxResults,
ListPermissionsResponse (..),
newListPermissionsResponse,
listPermissionsResponse_nextToken,
listPermissionsResponse_principalResourcePermissions,
listPermissionsResponse_httpStatus,
)
where
import qualified Amazonka.Core as Core
import Amazonka.LakeFormation.Types
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response
data ListPermissions = ListPermissions'
{
ListPermissions -> Maybe DataLakeResourceType
resourceType :: Prelude.Maybe DataLakeResourceType,
ListPermissions -> Maybe Text
catalogId :: Prelude.Maybe Prelude.Text,
ListPermissions -> Maybe Text
nextToken :: Prelude.Maybe Prelude.Text,
ListPermissions -> Maybe DataLakePrincipal
principal :: Prelude.Maybe DataLakePrincipal,
ListPermissions -> Maybe Resource
resource :: Prelude.Maybe Resource,
ListPermissions -> Maybe Natural
maxResults :: Prelude.Maybe Prelude.Natural
}
deriving (ListPermissions -> ListPermissions -> Bool
(ListPermissions -> ListPermissions -> Bool)
-> (ListPermissions -> ListPermissions -> Bool)
-> Eq ListPermissions
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ListPermissions -> ListPermissions -> Bool
$c/= :: ListPermissions -> ListPermissions -> Bool
== :: ListPermissions -> ListPermissions -> Bool
$c== :: ListPermissions -> ListPermissions -> Bool
Prelude.Eq, ReadPrec [ListPermissions]
ReadPrec ListPermissions
Int -> ReadS ListPermissions
ReadS [ListPermissions]
(Int -> ReadS ListPermissions)
-> ReadS [ListPermissions]
-> ReadPrec ListPermissions
-> ReadPrec [ListPermissions]
-> Read ListPermissions
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ListPermissions]
$creadListPrec :: ReadPrec [ListPermissions]
readPrec :: ReadPrec ListPermissions
$creadPrec :: ReadPrec ListPermissions
readList :: ReadS [ListPermissions]
$creadList :: ReadS [ListPermissions]
readsPrec :: Int -> ReadS ListPermissions
$creadsPrec :: Int -> ReadS ListPermissions
Prelude.Read, Int -> ListPermissions -> ShowS
[ListPermissions] -> ShowS
ListPermissions -> String
(Int -> ListPermissions -> ShowS)
-> (ListPermissions -> String)
-> ([ListPermissions] -> ShowS)
-> Show ListPermissions
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ListPermissions] -> ShowS
$cshowList :: [ListPermissions] -> ShowS
show :: ListPermissions -> String
$cshow :: ListPermissions -> String
showsPrec :: Int -> ListPermissions -> ShowS
$cshowsPrec :: Int -> ListPermissions -> ShowS
Prelude.Show, (forall x. ListPermissions -> Rep ListPermissions x)
-> (forall x. Rep ListPermissions x -> ListPermissions)
-> Generic ListPermissions
forall x. Rep ListPermissions x -> ListPermissions
forall x. ListPermissions -> Rep ListPermissions x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep ListPermissions x -> ListPermissions
$cfrom :: forall x. ListPermissions -> Rep ListPermissions x
Prelude.Generic)
newListPermissions ::
ListPermissions
newListPermissions :: ListPermissions
newListPermissions =
ListPermissions' :: Maybe DataLakeResourceType
-> Maybe Text
-> Maybe Text
-> Maybe DataLakePrincipal
-> Maybe Resource
-> Maybe Natural
-> ListPermissions
ListPermissions'
{ $sel:resourceType:ListPermissions' :: Maybe DataLakeResourceType
resourceType = Maybe DataLakeResourceType
forall a. Maybe a
Prelude.Nothing,
$sel:catalogId:ListPermissions' :: Maybe Text
catalogId = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:nextToken:ListPermissions' :: Maybe Text
nextToken = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:principal:ListPermissions' :: Maybe DataLakePrincipal
principal = Maybe DataLakePrincipal
forall a. Maybe a
Prelude.Nothing,
$sel:resource:ListPermissions' :: Maybe Resource
resource = Maybe Resource
forall a. Maybe a
Prelude.Nothing,
$sel:maxResults:ListPermissions' :: Maybe Natural
maxResults = Maybe Natural
forall a. Maybe a
Prelude.Nothing
}
listPermissions_resourceType :: Lens.Lens' ListPermissions (Prelude.Maybe DataLakeResourceType)
listPermissions_resourceType :: (Maybe DataLakeResourceType -> f (Maybe DataLakeResourceType))
-> ListPermissions -> f ListPermissions
listPermissions_resourceType = (ListPermissions -> Maybe DataLakeResourceType)
-> (ListPermissions
-> Maybe DataLakeResourceType -> ListPermissions)
-> Lens
ListPermissions
ListPermissions
(Maybe DataLakeResourceType)
(Maybe DataLakeResourceType)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListPermissions' {Maybe DataLakeResourceType
resourceType :: Maybe DataLakeResourceType
$sel:resourceType:ListPermissions' :: ListPermissions -> Maybe DataLakeResourceType
resourceType} -> Maybe DataLakeResourceType
resourceType) (\s :: ListPermissions
s@ListPermissions' {} Maybe DataLakeResourceType
a -> ListPermissions
s {$sel:resourceType:ListPermissions' :: Maybe DataLakeResourceType
resourceType = Maybe DataLakeResourceType
a} :: ListPermissions)
listPermissions_catalogId :: Lens.Lens' ListPermissions (Prelude.Maybe Prelude.Text)
listPermissions_catalogId :: (Maybe Text -> f (Maybe Text))
-> ListPermissions -> f ListPermissions
listPermissions_catalogId = (ListPermissions -> Maybe Text)
-> (ListPermissions -> Maybe Text -> ListPermissions)
-> Lens ListPermissions ListPermissions (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListPermissions' {Maybe Text
catalogId :: Maybe Text
$sel:catalogId:ListPermissions' :: ListPermissions -> Maybe Text
catalogId} -> Maybe Text
catalogId) (\s :: ListPermissions
s@ListPermissions' {} Maybe Text
a -> ListPermissions
s {$sel:catalogId:ListPermissions' :: Maybe Text
catalogId = Maybe Text
a} :: ListPermissions)
listPermissions_nextToken :: Lens.Lens' ListPermissions (Prelude.Maybe Prelude.Text)
listPermissions_nextToken :: (Maybe Text -> f (Maybe Text))
-> ListPermissions -> f ListPermissions
listPermissions_nextToken = (ListPermissions -> Maybe Text)
-> (ListPermissions -> Maybe Text -> ListPermissions)
-> Lens ListPermissions ListPermissions (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListPermissions' {Maybe Text
nextToken :: Maybe Text
$sel:nextToken:ListPermissions' :: ListPermissions -> Maybe Text
nextToken} -> Maybe Text
nextToken) (\s :: ListPermissions
s@ListPermissions' {} Maybe Text
a -> ListPermissions
s {$sel:nextToken:ListPermissions' :: Maybe Text
nextToken = Maybe Text
a} :: ListPermissions)
listPermissions_principal :: Lens.Lens' ListPermissions (Prelude.Maybe DataLakePrincipal)
listPermissions_principal :: (Maybe DataLakePrincipal -> f (Maybe DataLakePrincipal))
-> ListPermissions -> f ListPermissions
listPermissions_principal = (ListPermissions -> Maybe DataLakePrincipal)
-> (ListPermissions -> Maybe DataLakePrincipal -> ListPermissions)
-> Lens
ListPermissions
ListPermissions
(Maybe DataLakePrincipal)
(Maybe DataLakePrincipal)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListPermissions' {Maybe DataLakePrincipal
principal :: Maybe DataLakePrincipal
$sel:principal:ListPermissions' :: ListPermissions -> Maybe DataLakePrincipal
principal} -> Maybe DataLakePrincipal
principal) (\s :: ListPermissions
s@ListPermissions' {} Maybe DataLakePrincipal
a -> ListPermissions
s {$sel:principal:ListPermissions' :: Maybe DataLakePrincipal
principal = Maybe DataLakePrincipal
a} :: ListPermissions)
listPermissions_resource :: Lens.Lens' ListPermissions (Prelude.Maybe Resource)
listPermissions_resource :: (Maybe Resource -> f (Maybe Resource))
-> ListPermissions -> f ListPermissions
listPermissions_resource = (ListPermissions -> Maybe Resource)
-> (ListPermissions -> Maybe Resource -> ListPermissions)
-> Lens
ListPermissions ListPermissions (Maybe Resource) (Maybe Resource)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListPermissions' {Maybe Resource
resource :: Maybe Resource
$sel:resource:ListPermissions' :: ListPermissions -> Maybe Resource
resource} -> Maybe Resource
resource) (\s :: ListPermissions
s@ListPermissions' {} Maybe Resource
a -> ListPermissions
s {$sel:resource:ListPermissions' :: Maybe Resource
resource = Maybe Resource
a} :: ListPermissions)
listPermissions_maxResults :: Lens.Lens' ListPermissions (Prelude.Maybe Prelude.Natural)
listPermissions_maxResults :: (Maybe Natural -> f (Maybe Natural))
-> ListPermissions -> f ListPermissions
listPermissions_maxResults = (ListPermissions -> Maybe Natural)
-> (ListPermissions -> Maybe Natural -> ListPermissions)
-> Lens
ListPermissions ListPermissions (Maybe Natural) (Maybe Natural)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListPermissions' {Maybe Natural
maxResults :: Maybe Natural
$sel:maxResults:ListPermissions' :: ListPermissions -> Maybe Natural
maxResults} -> Maybe Natural
maxResults) (\s :: ListPermissions
s@ListPermissions' {} Maybe Natural
a -> ListPermissions
s {$sel:maxResults:ListPermissions' :: Maybe Natural
maxResults = Maybe Natural
a} :: ListPermissions)
instance Core.AWSRequest ListPermissions where
type
AWSResponse ListPermissions =
ListPermissionsResponse
request :: ListPermissions -> Request ListPermissions
request = Service -> ListPermissions -> Request ListPermissions
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.postJSON Service
defaultService
response :: Logger
-> Service
-> Proxy ListPermissions
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse ListPermissions)))
response =
(Int
-> ResponseHeaders
-> Object
-> Either String (AWSResponse ListPermissions))
-> Logger
-> Service
-> Proxy ListPermissions
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse ListPermissions)))
forall (m :: * -> *) a.
MonadResource m =>
(Int -> ResponseHeaders -> Object -> Either String (AWSResponse a))
-> Logger
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveJSON
( \Int
s ResponseHeaders
h Object
x ->
Maybe Text
-> Maybe [PrincipalResourcePermissions]
-> Int
-> ListPermissionsResponse
ListPermissionsResponse'
(Maybe Text
-> Maybe [PrincipalResourcePermissions]
-> Int
-> ListPermissionsResponse)
-> Either String (Maybe Text)
-> Either
String
(Maybe [PrincipalResourcePermissions]
-> Int -> ListPermissionsResponse)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Either String (Maybe Text)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"NextToken")
Either
String
(Maybe [PrincipalResourcePermissions]
-> Int -> ListPermissionsResponse)
-> Either String (Maybe [PrincipalResourcePermissions])
-> Either String (Int -> ListPermissionsResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( Object
x Object
-> Text
-> Either String (Maybe (Maybe [PrincipalResourcePermissions]))
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"PrincipalResourcePermissions"
Either String (Maybe (Maybe [PrincipalResourcePermissions]))
-> Maybe [PrincipalResourcePermissions]
-> Either String (Maybe [PrincipalResourcePermissions])
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ Maybe [PrincipalResourcePermissions]
forall a. Monoid a => a
Prelude.mempty
)
Either String (Int -> ListPermissionsResponse)
-> Either String Int -> Either String ListPermissionsResponse
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Int -> Either String Int
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure (Int -> Int
forall a. Enum a => a -> Int
Prelude.fromEnum Int
s))
)
instance Prelude.Hashable ListPermissions
instance Prelude.NFData ListPermissions
instance Core.ToHeaders ListPermissions where
toHeaders :: ListPermissions -> ResponseHeaders
toHeaders =
ResponseHeaders -> ListPermissions -> ResponseHeaders
forall a b. a -> b -> a
Prelude.const
( [ResponseHeaders] -> ResponseHeaders
forall a. Monoid a => [a] -> a
Prelude.mconcat
[ HeaderName
"X-Amz-Target"
HeaderName -> ByteString -> ResponseHeaders
forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Core.=# ( ByteString
"AWSLakeFormation.ListPermissions" ::
Prelude.ByteString
),
HeaderName
"Content-Type"
HeaderName -> ByteString -> ResponseHeaders
forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Core.=# ( ByteString
"application/x-amz-json-1.1" ::
Prelude.ByteString
)
]
)
instance Core.ToJSON ListPermissions where
toJSON :: ListPermissions -> Value
toJSON ListPermissions' {Maybe Natural
Maybe Text
Maybe DataLakePrincipal
Maybe DataLakeResourceType
Maybe Resource
maxResults :: Maybe Natural
resource :: Maybe Resource
principal :: Maybe DataLakePrincipal
nextToken :: Maybe Text
catalogId :: Maybe Text
resourceType :: Maybe DataLakeResourceType
$sel:maxResults:ListPermissions' :: ListPermissions -> Maybe Natural
$sel:resource:ListPermissions' :: ListPermissions -> Maybe Resource
$sel:principal:ListPermissions' :: ListPermissions -> Maybe DataLakePrincipal
$sel:nextToken:ListPermissions' :: ListPermissions -> Maybe Text
$sel:catalogId:ListPermissions' :: ListPermissions -> Maybe Text
$sel:resourceType:ListPermissions' :: ListPermissions -> Maybe DataLakeResourceType
..} =
[Pair] -> Value
Core.object
( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[ (Text
"ResourceType" Text -> DataLakeResourceType -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (DataLakeResourceType -> Pair)
-> Maybe DataLakeResourceType -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe DataLakeResourceType
resourceType,
(Text
"CatalogId" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
catalogId,
(Text
"NextToken" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
nextToken,
(Text
"Principal" Text -> DataLakePrincipal -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (DataLakePrincipal -> Pair)
-> Maybe DataLakePrincipal -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe DataLakePrincipal
principal,
(Text
"Resource" Text -> Resource -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Resource -> Pair) -> Maybe Resource -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Resource
resource,
(Text
"MaxResults" Text -> Natural -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Natural -> Pair) -> Maybe Natural -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Natural
maxResults
]
)
instance Core.ToPath ListPermissions where
toPath :: ListPermissions -> ByteString
toPath = ByteString -> ListPermissions -> ByteString
forall a b. a -> b -> a
Prelude.const ByteString
"/"
instance Core.ToQuery ListPermissions where
toQuery :: ListPermissions -> QueryString
toQuery = QueryString -> ListPermissions -> QueryString
forall a b. a -> b -> a
Prelude.const QueryString
forall a. Monoid a => a
Prelude.mempty
data ListPermissionsResponse = ListPermissionsResponse'
{
ListPermissionsResponse -> Maybe Text
nextToken :: Prelude.Maybe Prelude.Text,
ListPermissionsResponse -> Maybe [PrincipalResourcePermissions]
principalResourcePermissions :: Prelude.Maybe [PrincipalResourcePermissions],
ListPermissionsResponse -> Int
httpStatus :: Prelude.Int
}
deriving (ListPermissionsResponse -> ListPermissionsResponse -> Bool
(ListPermissionsResponse -> ListPermissionsResponse -> Bool)
-> (ListPermissionsResponse -> ListPermissionsResponse -> Bool)
-> Eq ListPermissionsResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ListPermissionsResponse -> ListPermissionsResponse -> Bool
$c/= :: ListPermissionsResponse -> ListPermissionsResponse -> Bool
== :: ListPermissionsResponse -> ListPermissionsResponse -> Bool
$c== :: ListPermissionsResponse -> ListPermissionsResponse -> Bool
Prelude.Eq, ReadPrec [ListPermissionsResponse]
ReadPrec ListPermissionsResponse
Int -> ReadS ListPermissionsResponse
ReadS [ListPermissionsResponse]
(Int -> ReadS ListPermissionsResponse)
-> ReadS [ListPermissionsResponse]
-> ReadPrec ListPermissionsResponse
-> ReadPrec [ListPermissionsResponse]
-> Read ListPermissionsResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ListPermissionsResponse]
$creadListPrec :: ReadPrec [ListPermissionsResponse]
readPrec :: ReadPrec ListPermissionsResponse
$creadPrec :: ReadPrec ListPermissionsResponse
readList :: ReadS [ListPermissionsResponse]
$creadList :: ReadS [ListPermissionsResponse]
readsPrec :: Int -> ReadS ListPermissionsResponse
$creadsPrec :: Int -> ReadS ListPermissionsResponse
Prelude.Read, Int -> ListPermissionsResponse -> ShowS
[ListPermissionsResponse] -> ShowS
ListPermissionsResponse -> String
(Int -> ListPermissionsResponse -> ShowS)
-> (ListPermissionsResponse -> String)
-> ([ListPermissionsResponse] -> ShowS)
-> Show ListPermissionsResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ListPermissionsResponse] -> ShowS
$cshowList :: [ListPermissionsResponse] -> ShowS
show :: ListPermissionsResponse -> String
$cshow :: ListPermissionsResponse -> String
showsPrec :: Int -> ListPermissionsResponse -> ShowS
$cshowsPrec :: Int -> ListPermissionsResponse -> ShowS
Prelude.Show, (forall x.
ListPermissionsResponse -> Rep ListPermissionsResponse x)
-> (forall x.
Rep ListPermissionsResponse x -> ListPermissionsResponse)
-> Generic ListPermissionsResponse
forall x. Rep ListPermissionsResponse x -> ListPermissionsResponse
forall x. ListPermissionsResponse -> Rep ListPermissionsResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep ListPermissionsResponse x -> ListPermissionsResponse
$cfrom :: forall x. ListPermissionsResponse -> Rep ListPermissionsResponse x
Prelude.Generic)
newListPermissionsResponse ::
Prelude.Int ->
ListPermissionsResponse
newListPermissionsResponse :: Int -> ListPermissionsResponse
newListPermissionsResponse Int
pHttpStatus_ =
ListPermissionsResponse' :: Maybe Text
-> Maybe [PrincipalResourcePermissions]
-> Int
-> ListPermissionsResponse
ListPermissionsResponse'
{ $sel:nextToken:ListPermissionsResponse' :: Maybe Text
nextToken =
Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:principalResourcePermissions:ListPermissionsResponse' :: Maybe [PrincipalResourcePermissions]
principalResourcePermissions = Maybe [PrincipalResourcePermissions]
forall a. Maybe a
Prelude.Nothing,
$sel:httpStatus:ListPermissionsResponse' :: Int
httpStatus = Int
pHttpStatus_
}
listPermissionsResponse_nextToken :: Lens.Lens' ListPermissionsResponse (Prelude.Maybe Prelude.Text)
listPermissionsResponse_nextToken :: (Maybe Text -> f (Maybe Text))
-> ListPermissionsResponse -> f ListPermissionsResponse
listPermissionsResponse_nextToken = (ListPermissionsResponse -> Maybe Text)
-> (ListPermissionsResponse
-> Maybe Text -> ListPermissionsResponse)
-> Lens
ListPermissionsResponse
ListPermissionsResponse
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListPermissionsResponse' {Maybe Text
nextToken :: Maybe Text
$sel:nextToken:ListPermissionsResponse' :: ListPermissionsResponse -> Maybe Text
nextToken} -> Maybe Text
nextToken) (\s :: ListPermissionsResponse
s@ListPermissionsResponse' {} Maybe Text
a -> ListPermissionsResponse
s {$sel:nextToken:ListPermissionsResponse' :: Maybe Text
nextToken = Maybe Text
a} :: ListPermissionsResponse)
listPermissionsResponse_principalResourcePermissions :: Lens.Lens' ListPermissionsResponse (Prelude.Maybe [PrincipalResourcePermissions])
listPermissionsResponse_principalResourcePermissions :: (Maybe [PrincipalResourcePermissions]
-> f (Maybe [PrincipalResourcePermissions]))
-> ListPermissionsResponse -> f ListPermissionsResponse
listPermissionsResponse_principalResourcePermissions = (ListPermissionsResponse -> Maybe [PrincipalResourcePermissions])
-> (ListPermissionsResponse
-> Maybe [PrincipalResourcePermissions] -> ListPermissionsResponse)
-> Lens
ListPermissionsResponse
ListPermissionsResponse
(Maybe [PrincipalResourcePermissions])
(Maybe [PrincipalResourcePermissions])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListPermissionsResponse' {Maybe [PrincipalResourcePermissions]
principalResourcePermissions :: Maybe [PrincipalResourcePermissions]
$sel:principalResourcePermissions:ListPermissionsResponse' :: ListPermissionsResponse -> Maybe [PrincipalResourcePermissions]
principalResourcePermissions} -> Maybe [PrincipalResourcePermissions]
principalResourcePermissions) (\s :: ListPermissionsResponse
s@ListPermissionsResponse' {} Maybe [PrincipalResourcePermissions]
a -> ListPermissionsResponse
s {$sel:principalResourcePermissions:ListPermissionsResponse' :: Maybe [PrincipalResourcePermissions]
principalResourcePermissions = Maybe [PrincipalResourcePermissions]
a} :: ListPermissionsResponse) ((Maybe [PrincipalResourcePermissions]
-> f (Maybe [PrincipalResourcePermissions]))
-> ListPermissionsResponse -> f ListPermissionsResponse)
-> ((Maybe [PrincipalResourcePermissions]
-> f (Maybe [PrincipalResourcePermissions]))
-> Maybe [PrincipalResourcePermissions]
-> f (Maybe [PrincipalResourcePermissions]))
-> (Maybe [PrincipalResourcePermissions]
-> f (Maybe [PrincipalResourcePermissions]))
-> ListPermissionsResponse
-> f ListPermissionsResponse
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
[PrincipalResourcePermissions]
[PrincipalResourcePermissions]
[PrincipalResourcePermissions]
[PrincipalResourcePermissions]
-> Iso
(Maybe [PrincipalResourcePermissions])
(Maybe [PrincipalResourcePermissions])
(Maybe [PrincipalResourcePermissions])
(Maybe [PrincipalResourcePermissions])
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
[PrincipalResourcePermissions]
[PrincipalResourcePermissions]
[PrincipalResourcePermissions]
[PrincipalResourcePermissions]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
listPermissionsResponse_httpStatus :: Lens.Lens' ListPermissionsResponse Prelude.Int
listPermissionsResponse_httpStatus :: (Int -> f Int)
-> ListPermissionsResponse -> f ListPermissionsResponse
listPermissionsResponse_httpStatus = (ListPermissionsResponse -> Int)
-> (ListPermissionsResponse -> Int -> ListPermissionsResponse)
-> Lens ListPermissionsResponse ListPermissionsResponse Int Int
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ListPermissionsResponse' {Int
httpStatus :: Int
$sel:httpStatus:ListPermissionsResponse' :: ListPermissionsResponse -> Int
httpStatus} -> Int
httpStatus) (\s :: ListPermissionsResponse
s@ListPermissionsResponse' {} Int
a -> ListPermissionsResponse
s {$sel:httpStatus:ListPermissionsResponse' :: Int
httpStatus = Int
a} :: ListPermissionsResponse)
instance Prelude.NFData ListPermissionsResponse