{-# 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.DirectoryService.DescribeDirectories
(
DescribeDirectories (..),
newDescribeDirectories,
describeDirectories_nextToken,
describeDirectories_directoryIds,
describeDirectories_limit,
DescribeDirectoriesResponse (..),
newDescribeDirectoriesResponse,
describeDirectoriesResponse_directoryDescriptions,
describeDirectoriesResponse_nextToken,
describeDirectoriesResponse_httpStatus,
)
where
import qualified Amazonka.Core as Core
import Amazonka.DirectoryService.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 DescribeDirectories = DescribeDirectories'
{
DescribeDirectories -> Maybe Text
nextToken :: Prelude.Maybe Prelude.Text,
DescribeDirectories -> Maybe [Text]
directoryIds :: Prelude.Maybe [Prelude.Text],
DescribeDirectories -> Maybe Natural
limit :: Prelude.Maybe Prelude.Natural
}
deriving (DescribeDirectories -> DescribeDirectories -> Bool
(DescribeDirectories -> DescribeDirectories -> Bool)
-> (DescribeDirectories -> DescribeDirectories -> Bool)
-> Eq DescribeDirectories
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DescribeDirectories -> DescribeDirectories -> Bool
$c/= :: DescribeDirectories -> DescribeDirectories -> Bool
== :: DescribeDirectories -> DescribeDirectories -> Bool
$c== :: DescribeDirectories -> DescribeDirectories -> Bool
Prelude.Eq, ReadPrec [DescribeDirectories]
ReadPrec DescribeDirectories
Int -> ReadS DescribeDirectories
ReadS [DescribeDirectories]
(Int -> ReadS DescribeDirectories)
-> ReadS [DescribeDirectories]
-> ReadPrec DescribeDirectories
-> ReadPrec [DescribeDirectories]
-> Read DescribeDirectories
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DescribeDirectories]
$creadListPrec :: ReadPrec [DescribeDirectories]
readPrec :: ReadPrec DescribeDirectories
$creadPrec :: ReadPrec DescribeDirectories
readList :: ReadS [DescribeDirectories]
$creadList :: ReadS [DescribeDirectories]
readsPrec :: Int -> ReadS DescribeDirectories
$creadsPrec :: Int -> ReadS DescribeDirectories
Prelude.Read, Int -> DescribeDirectories -> ShowS
[DescribeDirectories] -> ShowS
DescribeDirectories -> String
(Int -> DescribeDirectories -> ShowS)
-> (DescribeDirectories -> String)
-> ([DescribeDirectories] -> ShowS)
-> Show DescribeDirectories
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DescribeDirectories] -> ShowS
$cshowList :: [DescribeDirectories] -> ShowS
show :: DescribeDirectories -> String
$cshow :: DescribeDirectories -> String
showsPrec :: Int -> DescribeDirectories -> ShowS
$cshowsPrec :: Int -> DescribeDirectories -> ShowS
Prelude.Show, (forall x. DescribeDirectories -> Rep DescribeDirectories x)
-> (forall x. Rep DescribeDirectories x -> DescribeDirectories)
-> Generic DescribeDirectories
forall x. Rep DescribeDirectories x -> DescribeDirectories
forall x. DescribeDirectories -> Rep DescribeDirectories x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep DescribeDirectories x -> DescribeDirectories
$cfrom :: forall x. DescribeDirectories -> Rep DescribeDirectories x
Prelude.Generic)
newDescribeDirectories ::
DescribeDirectories
newDescribeDirectories :: DescribeDirectories
newDescribeDirectories =
DescribeDirectories' :: Maybe Text -> Maybe [Text] -> Maybe Natural -> DescribeDirectories
DescribeDirectories'
{ $sel:nextToken:DescribeDirectories' :: Maybe Text
nextToken = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:directoryIds:DescribeDirectories' :: Maybe [Text]
directoryIds = Maybe [Text]
forall a. Maybe a
Prelude.Nothing,
$sel:limit:DescribeDirectories' :: Maybe Natural
limit = Maybe Natural
forall a. Maybe a
Prelude.Nothing
}
describeDirectories_nextToken :: Lens.Lens' DescribeDirectories (Prelude.Maybe Prelude.Text)
describeDirectories_nextToken :: (Maybe Text -> f (Maybe Text))
-> DescribeDirectories -> f DescribeDirectories
describeDirectories_nextToken = (DescribeDirectories -> Maybe Text)
-> (DescribeDirectories -> Maybe Text -> DescribeDirectories)
-> Lens
DescribeDirectories DescribeDirectories (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeDirectories' {Maybe Text
nextToken :: Maybe Text
$sel:nextToken:DescribeDirectories' :: DescribeDirectories -> Maybe Text
nextToken} -> Maybe Text
nextToken) (\s :: DescribeDirectories
s@DescribeDirectories' {} Maybe Text
a -> DescribeDirectories
s {$sel:nextToken:DescribeDirectories' :: Maybe Text
nextToken = Maybe Text
a} :: DescribeDirectories)
describeDirectories_directoryIds :: Lens.Lens' DescribeDirectories (Prelude.Maybe [Prelude.Text])
describeDirectories_directoryIds :: (Maybe [Text] -> f (Maybe [Text]))
-> DescribeDirectories -> f DescribeDirectories
describeDirectories_directoryIds = (DescribeDirectories -> Maybe [Text])
-> (DescribeDirectories -> Maybe [Text] -> DescribeDirectories)
-> Lens
DescribeDirectories
DescribeDirectories
(Maybe [Text])
(Maybe [Text])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeDirectories' {Maybe [Text]
directoryIds :: Maybe [Text]
$sel:directoryIds:DescribeDirectories' :: DescribeDirectories -> Maybe [Text]
directoryIds} -> Maybe [Text]
directoryIds) (\s :: DescribeDirectories
s@DescribeDirectories' {} Maybe [Text]
a -> DescribeDirectories
s {$sel:directoryIds:DescribeDirectories' :: Maybe [Text]
directoryIds = Maybe [Text]
a} :: DescribeDirectories) ((Maybe [Text] -> f (Maybe [Text]))
-> DescribeDirectories -> f DescribeDirectories)
-> ((Maybe [Text] -> f (Maybe [Text]))
-> Maybe [Text] -> f (Maybe [Text]))
-> (Maybe [Text] -> f (Maybe [Text]))
-> DescribeDirectories
-> f DescribeDirectories
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso [Text] [Text] [Text] [Text]
-> Iso (Maybe [Text]) (Maybe [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 [Text] [Text] [Text] [Text]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
describeDirectories_limit :: Lens.Lens' DescribeDirectories (Prelude.Maybe Prelude.Natural)
describeDirectories_limit :: (Maybe Natural -> f (Maybe Natural))
-> DescribeDirectories -> f DescribeDirectories
describeDirectories_limit = (DescribeDirectories -> Maybe Natural)
-> (DescribeDirectories -> Maybe Natural -> DescribeDirectories)
-> Lens
DescribeDirectories
DescribeDirectories
(Maybe Natural)
(Maybe Natural)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeDirectories' {Maybe Natural
limit :: Maybe Natural
$sel:limit:DescribeDirectories' :: DescribeDirectories -> Maybe Natural
limit} -> Maybe Natural
limit) (\s :: DescribeDirectories
s@DescribeDirectories' {} Maybe Natural
a -> DescribeDirectories
s {$sel:limit:DescribeDirectories' :: Maybe Natural
limit = Maybe Natural
a} :: DescribeDirectories)
instance Core.AWSPager DescribeDirectories where
page :: DescribeDirectories
-> AWSResponse DescribeDirectories -> Maybe DescribeDirectories
page DescribeDirectories
rq AWSResponse DescribeDirectories
rs
| Maybe Text -> Bool
forall a. AWSTruncated a => a -> Bool
Core.stop
( AWSResponse DescribeDirectories
DescribeDirectoriesResponse
rs
DescribeDirectoriesResponse
-> Getting (First Text) DescribeDirectoriesResponse Text
-> Maybe Text
forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? (Maybe Text -> Const (First Text) (Maybe Text))
-> DescribeDirectoriesResponse
-> Const (First Text) DescribeDirectoriesResponse
Lens' DescribeDirectoriesResponse (Maybe Text)
describeDirectoriesResponse_nextToken
((Maybe Text -> Const (First Text) (Maybe Text))
-> DescribeDirectoriesResponse
-> Const (First Text) DescribeDirectoriesResponse)
-> ((Text -> Const (First Text) Text)
-> Maybe Text -> Const (First Text) (Maybe Text))
-> Getting (First Text) DescribeDirectoriesResponse Text
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. (Text -> Const (First Text) Text)
-> Maybe Text -> Const (First Text) (Maybe Text)
forall a b. Prism (Maybe a) (Maybe b) a b
Lens._Just
) =
Maybe DescribeDirectories
forall a. Maybe a
Prelude.Nothing
| Maybe [DirectoryDescription] -> Bool
forall a. AWSTruncated a => a -> Bool
Core.stop
( AWSResponse DescribeDirectories
DescribeDirectoriesResponse
rs
DescribeDirectoriesResponse
-> Getting
(First [DirectoryDescription])
DescribeDirectoriesResponse
[DirectoryDescription]
-> Maybe [DirectoryDescription]
forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? (Maybe [DirectoryDescription]
-> Const
(First [DirectoryDescription]) (Maybe [DirectoryDescription]))
-> DescribeDirectoriesResponse
-> Const (First [DirectoryDescription]) DescribeDirectoriesResponse
Lens' DescribeDirectoriesResponse (Maybe [DirectoryDescription])
describeDirectoriesResponse_directoryDescriptions
((Maybe [DirectoryDescription]
-> Const
(First [DirectoryDescription]) (Maybe [DirectoryDescription]))
-> DescribeDirectoriesResponse
-> Const
(First [DirectoryDescription]) DescribeDirectoriesResponse)
-> (([DirectoryDescription]
-> Const (First [DirectoryDescription]) [DirectoryDescription])
-> Maybe [DirectoryDescription]
-> Const
(First [DirectoryDescription]) (Maybe [DirectoryDescription]))
-> Getting
(First [DirectoryDescription])
DescribeDirectoriesResponse
[DirectoryDescription]
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. ([DirectoryDescription]
-> Const (First [DirectoryDescription]) [DirectoryDescription])
-> Maybe [DirectoryDescription]
-> Const
(First [DirectoryDescription]) (Maybe [DirectoryDescription])
forall a b. Prism (Maybe a) (Maybe b) a b
Lens._Just
) =
Maybe DescribeDirectories
forall a. Maybe a
Prelude.Nothing
| Bool
Prelude.otherwise =
DescribeDirectories -> Maybe DescribeDirectories
forall a. a -> Maybe a
Prelude.Just (DescribeDirectories -> Maybe DescribeDirectories)
-> DescribeDirectories -> Maybe DescribeDirectories
forall a b. (a -> b) -> a -> b
Prelude.$
DescribeDirectories
rq
DescribeDirectories
-> (DescribeDirectories -> DescribeDirectories)
-> DescribeDirectories
forall a b. a -> (a -> b) -> b
Prelude.& (Maybe Text -> Identity (Maybe Text))
-> DescribeDirectories -> Identity DescribeDirectories
Lens
DescribeDirectories DescribeDirectories (Maybe Text) (Maybe Text)
describeDirectories_nextToken
((Maybe Text -> Identity (Maybe Text))
-> DescribeDirectories -> Identity DescribeDirectories)
-> Maybe Text -> DescribeDirectories -> DescribeDirectories
forall s t a b. ASetter s t a b -> b -> s -> t
Lens..~ AWSResponse DescribeDirectories
DescribeDirectoriesResponse
rs
DescribeDirectoriesResponse
-> Getting (First Text) DescribeDirectoriesResponse Text
-> Maybe Text
forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? (Maybe Text -> Const (First Text) (Maybe Text))
-> DescribeDirectoriesResponse
-> Const (First Text) DescribeDirectoriesResponse
Lens' DescribeDirectoriesResponse (Maybe Text)
describeDirectoriesResponse_nextToken
((Maybe Text -> Const (First Text) (Maybe Text))
-> DescribeDirectoriesResponse
-> Const (First Text) DescribeDirectoriesResponse)
-> ((Text -> Const (First Text) Text)
-> Maybe Text -> Const (First Text) (Maybe Text))
-> Getting (First Text) DescribeDirectoriesResponse Text
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. (Text -> Const (First Text) Text)
-> Maybe Text -> Const (First Text) (Maybe Text)
forall a b. Prism (Maybe a) (Maybe b) a b
Lens._Just
instance Core.AWSRequest DescribeDirectories where
type
AWSResponse DescribeDirectories =
DescribeDirectoriesResponse
request :: DescribeDirectories -> Request DescribeDirectories
request = Service -> DescribeDirectories -> Request DescribeDirectories
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.postJSON Service
defaultService
response :: Logger
-> Service
-> Proxy DescribeDirectories
-> ClientResponse ClientBody
-> m (Either
Error (ClientResponse (AWSResponse DescribeDirectories)))
response =
(Int
-> ResponseHeaders
-> Object
-> Either String (AWSResponse DescribeDirectories))
-> Logger
-> Service
-> Proxy DescribeDirectories
-> ClientResponse ClientBody
-> m (Either
Error (ClientResponse (AWSResponse DescribeDirectories)))
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 [DirectoryDescription]
-> Maybe Text -> Int -> DescribeDirectoriesResponse
DescribeDirectoriesResponse'
(Maybe [DirectoryDescription]
-> Maybe Text -> Int -> DescribeDirectoriesResponse)
-> Either String (Maybe [DirectoryDescription])
-> Either String (Maybe Text -> Int -> DescribeDirectoriesResponse)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> ( Object
x Object
-> Text -> Either String (Maybe (Maybe [DirectoryDescription]))
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"DirectoryDescriptions"
Either String (Maybe (Maybe [DirectoryDescription]))
-> Maybe [DirectoryDescription]
-> Either String (Maybe [DirectoryDescription])
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ Maybe [DirectoryDescription]
forall a. Monoid a => a
Prelude.mempty
)
Either String (Maybe Text -> Int -> DescribeDirectoriesResponse)
-> Either String (Maybe Text)
-> Either String (Int -> DescribeDirectoriesResponse)
forall (f :: * -> *) a b. Applicative f => 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 (Int -> DescribeDirectoriesResponse)
-> Either String Int -> Either String DescribeDirectoriesResponse
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 DescribeDirectories
instance Prelude.NFData DescribeDirectories
instance Core.ToHeaders DescribeDirectories where
toHeaders :: DescribeDirectories -> ResponseHeaders
toHeaders =
ResponseHeaders -> DescribeDirectories -> 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
"DirectoryService_20150416.DescribeDirectories" ::
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 DescribeDirectories where
toJSON :: DescribeDirectories -> Value
toJSON DescribeDirectories' {Maybe Natural
Maybe [Text]
Maybe Text
limit :: Maybe Natural
directoryIds :: Maybe [Text]
nextToken :: Maybe Text
$sel:limit:DescribeDirectories' :: DescribeDirectories -> Maybe Natural
$sel:directoryIds:DescribeDirectories' :: DescribeDirectories -> Maybe [Text]
$sel:nextToken:DescribeDirectories' :: DescribeDirectories -> Maybe Text
..} =
[Pair] -> Value
Core.object
( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[ (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
"DirectoryIds" 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]
directoryIds,
(Text
"Limit" 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
limit
]
)
instance Core.ToPath DescribeDirectories where
toPath :: DescribeDirectories -> ByteString
toPath = ByteString -> DescribeDirectories -> ByteString
forall a b. a -> b -> a
Prelude.const ByteString
"/"
instance Core.ToQuery DescribeDirectories where
toQuery :: DescribeDirectories -> QueryString
toQuery = QueryString -> DescribeDirectories -> QueryString
forall a b. a -> b -> a
Prelude.const QueryString
forall a. Monoid a => a
Prelude.mempty
data DescribeDirectoriesResponse = DescribeDirectoriesResponse'
{
DescribeDirectoriesResponse -> Maybe [DirectoryDescription]
directoryDescriptions :: Prelude.Maybe [DirectoryDescription],
DescribeDirectoriesResponse -> Maybe Text
nextToken :: Prelude.Maybe Prelude.Text,
DescribeDirectoriesResponse -> Int
httpStatus :: Prelude.Int
}
deriving (DescribeDirectoriesResponse -> DescribeDirectoriesResponse -> Bool
(DescribeDirectoriesResponse
-> DescribeDirectoriesResponse -> Bool)
-> (DescribeDirectoriesResponse
-> DescribeDirectoriesResponse -> Bool)
-> Eq DescribeDirectoriesResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DescribeDirectoriesResponse -> DescribeDirectoriesResponse -> Bool
$c/= :: DescribeDirectoriesResponse -> DescribeDirectoriesResponse -> Bool
== :: DescribeDirectoriesResponse -> DescribeDirectoriesResponse -> Bool
$c== :: DescribeDirectoriesResponse -> DescribeDirectoriesResponse -> Bool
Prelude.Eq, Int -> DescribeDirectoriesResponse -> ShowS
[DescribeDirectoriesResponse] -> ShowS
DescribeDirectoriesResponse -> String
(Int -> DescribeDirectoriesResponse -> ShowS)
-> (DescribeDirectoriesResponse -> String)
-> ([DescribeDirectoriesResponse] -> ShowS)
-> Show DescribeDirectoriesResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DescribeDirectoriesResponse] -> ShowS
$cshowList :: [DescribeDirectoriesResponse] -> ShowS
show :: DescribeDirectoriesResponse -> String
$cshow :: DescribeDirectoriesResponse -> String
showsPrec :: Int -> DescribeDirectoriesResponse -> ShowS
$cshowsPrec :: Int -> DescribeDirectoriesResponse -> ShowS
Prelude.Show, (forall x.
DescribeDirectoriesResponse -> Rep DescribeDirectoriesResponse x)
-> (forall x.
Rep DescribeDirectoriesResponse x -> DescribeDirectoriesResponse)
-> Generic DescribeDirectoriesResponse
forall x.
Rep DescribeDirectoriesResponse x -> DescribeDirectoriesResponse
forall x.
DescribeDirectoriesResponse -> Rep DescribeDirectoriesResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep DescribeDirectoriesResponse x -> DescribeDirectoriesResponse
$cfrom :: forall x.
DescribeDirectoriesResponse -> Rep DescribeDirectoriesResponse x
Prelude.Generic)
newDescribeDirectoriesResponse ::
Prelude.Int ->
DescribeDirectoriesResponse
newDescribeDirectoriesResponse :: Int -> DescribeDirectoriesResponse
newDescribeDirectoriesResponse Int
pHttpStatus_ =
DescribeDirectoriesResponse' :: Maybe [DirectoryDescription]
-> Maybe Text -> Int -> DescribeDirectoriesResponse
DescribeDirectoriesResponse'
{ $sel:directoryDescriptions:DescribeDirectoriesResponse' :: Maybe [DirectoryDescription]
directoryDescriptions =
Maybe [DirectoryDescription]
forall a. Maybe a
Prelude.Nothing,
$sel:nextToken:DescribeDirectoriesResponse' :: Maybe Text
nextToken = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:httpStatus:DescribeDirectoriesResponse' :: Int
httpStatus = Int
pHttpStatus_
}
describeDirectoriesResponse_directoryDescriptions :: Lens.Lens' DescribeDirectoriesResponse (Prelude.Maybe [DirectoryDescription])
describeDirectoriesResponse_directoryDescriptions :: (Maybe [DirectoryDescription] -> f (Maybe [DirectoryDescription]))
-> DescribeDirectoriesResponse -> f DescribeDirectoriesResponse
describeDirectoriesResponse_directoryDescriptions = (DescribeDirectoriesResponse -> Maybe [DirectoryDescription])
-> (DescribeDirectoriesResponse
-> Maybe [DirectoryDescription] -> DescribeDirectoriesResponse)
-> Lens' DescribeDirectoriesResponse (Maybe [DirectoryDescription])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeDirectoriesResponse' {Maybe [DirectoryDescription]
directoryDescriptions :: Maybe [DirectoryDescription]
$sel:directoryDescriptions:DescribeDirectoriesResponse' :: DescribeDirectoriesResponse -> Maybe [DirectoryDescription]
directoryDescriptions} -> Maybe [DirectoryDescription]
directoryDescriptions) (\s :: DescribeDirectoriesResponse
s@DescribeDirectoriesResponse' {} Maybe [DirectoryDescription]
a -> DescribeDirectoriesResponse
s {$sel:directoryDescriptions:DescribeDirectoriesResponse' :: Maybe [DirectoryDescription]
directoryDescriptions = Maybe [DirectoryDescription]
a} :: DescribeDirectoriesResponse) ((Maybe [DirectoryDescription] -> f (Maybe [DirectoryDescription]))
-> DescribeDirectoriesResponse -> f DescribeDirectoriesResponse)
-> ((Maybe [DirectoryDescription]
-> f (Maybe [DirectoryDescription]))
-> Maybe [DirectoryDescription]
-> f (Maybe [DirectoryDescription]))
-> (Maybe [DirectoryDescription]
-> f (Maybe [DirectoryDescription]))
-> DescribeDirectoriesResponse
-> f DescribeDirectoriesResponse
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
[DirectoryDescription]
[DirectoryDescription]
[DirectoryDescription]
[DirectoryDescription]
-> Iso
(Maybe [DirectoryDescription])
(Maybe [DirectoryDescription])
(Maybe [DirectoryDescription])
(Maybe [DirectoryDescription])
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
[DirectoryDescription]
[DirectoryDescription]
[DirectoryDescription]
[DirectoryDescription]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
describeDirectoriesResponse_nextToken :: Lens.Lens' DescribeDirectoriesResponse (Prelude.Maybe Prelude.Text)
describeDirectoriesResponse_nextToken :: (Maybe Text -> f (Maybe Text))
-> DescribeDirectoriesResponse -> f DescribeDirectoriesResponse
describeDirectoriesResponse_nextToken = (DescribeDirectoriesResponse -> Maybe Text)
-> (DescribeDirectoriesResponse
-> Maybe Text -> DescribeDirectoriesResponse)
-> Lens' DescribeDirectoriesResponse (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeDirectoriesResponse' {Maybe Text
nextToken :: Maybe Text
$sel:nextToken:DescribeDirectoriesResponse' :: DescribeDirectoriesResponse -> Maybe Text
nextToken} -> Maybe Text
nextToken) (\s :: DescribeDirectoriesResponse
s@DescribeDirectoriesResponse' {} Maybe Text
a -> DescribeDirectoriesResponse
s {$sel:nextToken:DescribeDirectoriesResponse' :: Maybe Text
nextToken = Maybe Text
a} :: DescribeDirectoriesResponse)
describeDirectoriesResponse_httpStatus :: Lens.Lens' DescribeDirectoriesResponse Prelude.Int
describeDirectoriesResponse_httpStatus :: (Int -> f Int)
-> DescribeDirectoriesResponse -> f DescribeDirectoriesResponse
describeDirectoriesResponse_httpStatus = (DescribeDirectoriesResponse -> Int)
-> (DescribeDirectoriesResponse
-> Int -> DescribeDirectoriesResponse)
-> Lens
DescribeDirectoriesResponse DescribeDirectoriesResponse Int Int
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeDirectoriesResponse' {Int
httpStatus :: Int
$sel:httpStatus:DescribeDirectoriesResponse' :: DescribeDirectoriesResponse -> Int
httpStatus} -> Int
httpStatus) (\s :: DescribeDirectoriesResponse
s@DescribeDirectoriesResponse' {} Int
a -> DescribeDirectoriesResponse
s {$sel:httpStatus:DescribeDirectoriesResponse' :: Int
httpStatus = Int
a} :: DescribeDirectoriesResponse)
instance Prelude.NFData DescribeDirectoriesResponse