{-# 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.Redshift.DescribeClusterSubnetGroups
(
DescribeClusterSubnetGroups (..),
newDescribeClusterSubnetGroups,
describeClusterSubnetGroups_tagValues,
describeClusterSubnetGroups_tagKeys,
describeClusterSubnetGroups_clusterSubnetGroupName,
describeClusterSubnetGroups_marker,
describeClusterSubnetGroups_maxRecords,
DescribeClusterSubnetGroupsResponse (..),
newDescribeClusterSubnetGroupsResponse,
describeClusterSubnetGroupsResponse_clusterSubnetGroups,
describeClusterSubnetGroupsResponse_marker,
describeClusterSubnetGroupsResponse_httpStatus,
)
where
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
import Amazonka.Redshift.Types
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response
data DescribeClusterSubnetGroups = DescribeClusterSubnetGroups'
{
DescribeClusterSubnetGroups -> Maybe [Text]
tagValues :: Prelude.Maybe [Prelude.Text],
DescribeClusterSubnetGroups -> Maybe [Text]
tagKeys :: Prelude.Maybe [Prelude.Text],
DescribeClusterSubnetGroups -> Maybe Text
clusterSubnetGroupName :: Prelude.Maybe Prelude.Text,
DescribeClusterSubnetGroups -> Maybe Text
marker :: Prelude.Maybe Prelude.Text,
DescribeClusterSubnetGroups -> Maybe Int
maxRecords :: Prelude.Maybe Prelude.Int
}
deriving (DescribeClusterSubnetGroups -> DescribeClusterSubnetGroups -> Bool
(DescribeClusterSubnetGroups
-> DescribeClusterSubnetGroups -> Bool)
-> (DescribeClusterSubnetGroups
-> DescribeClusterSubnetGroups -> Bool)
-> Eq DescribeClusterSubnetGroups
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DescribeClusterSubnetGroups -> DescribeClusterSubnetGroups -> Bool
$c/= :: DescribeClusterSubnetGroups -> DescribeClusterSubnetGroups -> Bool
== :: DescribeClusterSubnetGroups -> DescribeClusterSubnetGroups -> Bool
$c== :: DescribeClusterSubnetGroups -> DescribeClusterSubnetGroups -> Bool
Prelude.Eq, ReadPrec [DescribeClusterSubnetGroups]
ReadPrec DescribeClusterSubnetGroups
Int -> ReadS DescribeClusterSubnetGroups
ReadS [DescribeClusterSubnetGroups]
(Int -> ReadS DescribeClusterSubnetGroups)
-> ReadS [DescribeClusterSubnetGroups]
-> ReadPrec DescribeClusterSubnetGroups
-> ReadPrec [DescribeClusterSubnetGroups]
-> Read DescribeClusterSubnetGroups
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DescribeClusterSubnetGroups]
$creadListPrec :: ReadPrec [DescribeClusterSubnetGroups]
readPrec :: ReadPrec DescribeClusterSubnetGroups
$creadPrec :: ReadPrec DescribeClusterSubnetGroups
readList :: ReadS [DescribeClusterSubnetGroups]
$creadList :: ReadS [DescribeClusterSubnetGroups]
readsPrec :: Int -> ReadS DescribeClusterSubnetGroups
$creadsPrec :: Int -> ReadS DescribeClusterSubnetGroups
Prelude.Read, Int -> DescribeClusterSubnetGroups -> ShowS
[DescribeClusterSubnetGroups] -> ShowS
DescribeClusterSubnetGroups -> String
(Int -> DescribeClusterSubnetGroups -> ShowS)
-> (DescribeClusterSubnetGroups -> String)
-> ([DescribeClusterSubnetGroups] -> ShowS)
-> Show DescribeClusterSubnetGroups
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DescribeClusterSubnetGroups] -> ShowS
$cshowList :: [DescribeClusterSubnetGroups] -> ShowS
show :: DescribeClusterSubnetGroups -> String
$cshow :: DescribeClusterSubnetGroups -> String
showsPrec :: Int -> DescribeClusterSubnetGroups -> ShowS
$cshowsPrec :: Int -> DescribeClusterSubnetGroups -> ShowS
Prelude.Show, (forall x.
DescribeClusterSubnetGroups -> Rep DescribeClusterSubnetGroups x)
-> (forall x.
Rep DescribeClusterSubnetGroups x -> DescribeClusterSubnetGroups)
-> Generic DescribeClusterSubnetGroups
forall x.
Rep DescribeClusterSubnetGroups x -> DescribeClusterSubnetGroups
forall x.
DescribeClusterSubnetGroups -> Rep DescribeClusterSubnetGroups x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep DescribeClusterSubnetGroups x -> DescribeClusterSubnetGroups
$cfrom :: forall x.
DescribeClusterSubnetGroups -> Rep DescribeClusterSubnetGroups x
Prelude.Generic)
newDescribeClusterSubnetGroups ::
DescribeClusterSubnetGroups
newDescribeClusterSubnetGroups :: DescribeClusterSubnetGroups
newDescribeClusterSubnetGroups =
DescribeClusterSubnetGroups' :: Maybe [Text]
-> Maybe [Text]
-> Maybe Text
-> Maybe Text
-> Maybe Int
-> DescribeClusterSubnetGroups
DescribeClusterSubnetGroups'
{ $sel:tagValues:DescribeClusterSubnetGroups' :: Maybe [Text]
tagValues =
Maybe [Text]
forall a. Maybe a
Prelude.Nothing,
$sel:tagKeys:DescribeClusterSubnetGroups' :: Maybe [Text]
tagKeys = Maybe [Text]
forall a. Maybe a
Prelude.Nothing,
$sel:clusterSubnetGroupName:DescribeClusterSubnetGroups' :: Maybe Text
clusterSubnetGroupName = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:marker:DescribeClusterSubnetGroups' :: Maybe Text
marker = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:maxRecords:DescribeClusterSubnetGroups' :: Maybe Int
maxRecords = Maybe Int
forall a. Maybe a
Prelude.Nothing
}
describeClusterSubnetGroups_tagValues :: Lens.Lens' DescribeClusterSubnetGroups (Prelude.Maybe [Prelude.Text])
describeClusterSubnetGroups_tagValues :: (Maybe [Text] -> f (Maybe [Text]))
-> DescribeClusterSubnetGroups -> f DescribeClusterSubnetGroups
describeClusterSubnetGroups_tagValues = (DescribeClusterSubnetGroups -> Maybe [Text])
-> (DescribeClusterSubnetGroups
-> Maybe [Text] -> DescribeClusterSubnetGroups)
-> Lens
DescribeClusterSubnetGroups
DescribeClusterSubnetGroups
(Maybe [Text])
(Maybe [Text])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeClusterSubnetGroups' {Maybe [Text]
tagValues :: Maybe [Text]
$sel:tagValues:DescribeClusterSubnetGroups' :: DescribeClusterSubnetGroups -> Maybe [Text]
tagValues} -> Maybe [Text]
tagValues) (\s :: DescribeClusterSubnetGroups
s@DescribeClusterSubnetGroups' {} Maybe [Text]
a -> DescribeClusterSubnetGroups
s {$sel:tagValues:DescribeClusterSubnetGroups' :: Maybe [Text]
tagValues = Maybe [Text]
a} :: DescribeClusterSubnetGroups) ((Maybe [Text] -> f (Maybe [Text]))
-> DescribeClusterSubnetGroups -> f DescribeClusterSubnetGroups)
-> ((Maybe [Text] -> f (Maybe [Text]))
-> Maybe [Text] -> f (Maybe [Text]))
-> (Maybe [Text] -> f (Maybe [Text]))
-> DescribeClusterSubnetGroups
-> f DescribeClusterSubnetGroups
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
describeClusterSubnetGroups_tagKeys :: Lens.Lens' DescribeClusterSubnetGroups (Prelude.Maybe [Prelude.Text])
describeClusterSubnetGroups_tagKeys :: (Maybe [Text] -> f (Maybe [Text]))
-> DescribeClusterSubnetGroups -> f DescribeClusterSubnetGroups
describeClusterSubnetGroups_tagKeys = (DescribeClusterSubnetGroups -> Maybe [Text])
-> (DescribeClusterSubnetGroups
-> Maybe [Text] -> DescribeClusterSubnetGroups)
-> Lens
DescribeClusterSubnetGroups
DescribeClusterSubnetGroups
(Maybe [Text])
(Maybe [Text])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeClusterSubnetGroups' {Maybe [Text]
tagKeys :: Maybe [Text]
$sel:tagKeys:DescribeClusterSubnetGroups' :: DescribeClusterSubnetGroups -> Maybe [Text]
tagKeys} -> Maybe [Text]
tagKeys) (\s :: DescribeClusterSubnetGroups
s@DescribeClusterSubnetGroups' {} Maybe [Text]
a -> DescribeClusterSubnetGroups
s {$sel:tagKeys:DescribeClusterSubnetGroups' :: Maybe [Text]
tagKeys = Maybe [Text]
a} :: DescribeClusterSubnetGroups) ((Maybe [Text] -> f (Maybe [Text]))
-> DescribeClusterSubnetGroups -> f DescribeClusterSubnetGroups)
-> ((Maybe [Text] -> f (Maybe [Text]))
-> Maybe [Text] -> f (Maybe [Text]))
-> (Maybe [Text] -> f (Maybe [Text]))
-> DescribeClusterSubnetGroups
-> f DescribeClusterSubnetGroups
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
describeClusterSubnetGroups_clusterSubnetGroupName :: Lens.Lens' DescribeClusterSubnetGroups (Prelude.Maybe Prelude.Text)
describeClusterSubnetGroups_clusterSubnetGroupName :: (Maybe Text -> f (Maybe Text))
-> DescribeClusterSubnetGroups -> f DescribeClusterSubnetGroups
describeClusterSubnetGroups_clusterSubnetGroupName = (DescribeClusterSubnetGroups -> Maybe Text)
-> (DescribeClusterSubnetGroups
-> Maybe Text -> DescribeClusterSubnetGroups)
-> Lens
DescribeClusterSubnetGroups
DescribeClusterSubnetGroups
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeClusterSubnetGroups' {Maybe Text
clusterSubnetGroupName :: Maybe Text
$sel:clusterSubnetGroupName:DescribeClusterSubnetGroups' :: DescribeClusterSubnetGroups -> Maybe Text
clusterSubnetGroupName} -> Maybe Text
clusterSubnetGroupName) (\s :: DescribeClusterSubnetGroups
s@DescribeClusterSubnetGroups' {} Maybe Text
a -> DescribeClusterSubnetGroups
s {$sel:clusterSubnetGroupName:DescribeClusterSubnetGroups' :: Maybe Text
clusterSubnetGroupName = Maybe Text
a} :: DescribeClusterSubnetGroups)
describeClusterSubnetGroups_marker :: Lens.Lens' DescribeClusterSubnetGroups (Prelude.Maybe Prelude.Text)
describeClusterSubnetGroups_marker :: (Maybe Text -> f (Maybe Text))
-> DescribeClusterSubnetGroups -> f DescribeClusterSubnetGroups
describeClusterSubnetGroups_marker = (DescribeClusterSubnetGroups -> Maybe Text)
-> (DescribeClusterSubnetGroups
-> Maybe Text -> DescribeClusterSubnetGroups)
-> Lens
DescribeClusterSubnetGroups
DescribeClusterSubnetGroups
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeClusterSubnetGroups' {Maybe Text
marker :: Maybe Text
$sel:marker:DescribeClusterSubnetGroups' :: DescribeClusterSubnetGroups -> Maybe Text
marker} -> Maybe Text
marker) (\s :: DescribeClusterSubnetGroups
s@DescribeClusterSubnetGroups' {} Maybe Text
a -> DescribeClusterSubnetGroups
s {$sel:marker:DescribeClusterSubnetGroups' :: Maybe Text
marker = Maybe Text
a} :: DescribeClusterSubnetGroups)
describeClusterSubnetGroups_maxRecords :: Lens.Lens' DescribeClusterSubnetGroups (Prelude.Maybe Prelude.Int)
describeClusterSubnetGroups_maxRecords :: (Maybe Int -> f (Maybe Int))
-> DescribeClusterSubnetGroups -> f DescribeClusterSubnetGroups
describeClusterSubnetGroups_maxRecords = (DescribeClusterSubnetGroups -> Maybe Int)
-> (DescribeClusterSubnetGroups
-> Maybe Int -> DescribeClusterSubnetGroups)
-> Lens
DescribeClusterSubnetGroups
DescribeClusterSubnetGroups
(Maybe Int)
(Maybe Int)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeClusterSubnetGroups' {Maybe Int
maxRecords :: Maybe Int
$sel:maxRecords:DescribeClusterSubnetGroups' :: DescribeClusterSubnetGroups -> Maybe Int
maxRecords} -> Maybe Int
maxRecords) (\s :: DescribeClusterSubnetGroups
s@DescribeClusterSubnetGroups' {} Maybe Int
a -> DescribeClusterSubnetGroups
s {$sel:maxRecords:DescribeClusterSubnetGroups' :: Maybe Int
maxRecords = Maybe Int
a} :: DescribeClusterSubnetGroups)
instance Core.AWSPager DescribeClusterSubnetGroups where
page :: DescribeClusterSubnetGroups
-> AWSResponse DescribeClusterSubnetGroups
-> Maybe DescribeClusterSubnetGroups
page DescribeClusterSubnetGroups
rq AWSResponse DescribeClusterSubnetGroups
rs
| Maybe Text -> Bool
forall a. AWSTruncated a => a -> Bool
Core.stop
( AWSResponse DescribeClusterSubnetGroups
DescribeClusterSubnetGroupsResponse
rs
DescribeClusterSubnetGroupsResponse
-> Getting (First Text) DescribeClusterSubnetGroupsResponse Text
-> Maybe Text
forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? (Maybe Text -> Const (First Text) (Maybe Text))
-> DescribeClusterSubnetGroupsResponse
-> Const (First Text) DescribeClusterSubnetGroupsResponse
Lens' DescribeClusterSubnetGroupsResponse (Maybe Text)
describeClusterSubnetGroupsResponse_marker
((Maybe Text -> Const (First Text) (Maybe Text))
-> DescribeClusterSubnetGroupsResponse
-> Const (First Text) DescribeClusterSubnetGroupsResponse)
-> ((Text -> Const (First Text) Text)
-> Maybe Text -> Const (First Text) (Maybe Text))
-> Getting (First Text) DescribeClusterSubnetGroupsResponse 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 DescribeClusterSubnetGroups
forall a. Maybe a
Prelude.Nothing
| Maybe [ClusterSubnetGroup] -> Bool
forall a. AWSTruncated a => a -> Bool
Core.stop
( AWSResponse DescribeClusterSubnetGroups
DescribeClusterSubnetGroupsResponse
rs
DescribeClusterSubnetGroupsResponse
-> Getting
(First [ClusterSubnetGroup])
DescribeClusterSubnetGroupsResponse
[ClusterSubnetGroup]
-> Maybe [ClusterSubnetGroup]
forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? (Maybe [ClusterSubnetGroup]
-> Const (First [ClusterSubnetGroup]) (Maybe [ClusterSubnetGroup]))
-> DescribeClusterSubnetGroupsResponse
-> Const
(First [ClusterSubnetGroup]) DescribeClusterSubnetGroupsResponse
Lens'
DescribeClusterSubnetGroupsResponse (Maybe [ClusterSubnetGroup])
describeClusterSubnetGroupsResponse_clusterSubnetGroups
((Maybe [ClusterSubnetGroup]
-> Const (First [ClusterSubnetGroup]) (Maybe [ClusterSubnetGroup]))
-> DescribeClusterSubnetGroupsResponse
-> Const
(First [ClusterSubnetGroup]) DescribeClusterSubnetGroupsResponse)
-> (([ClusterSubnetGroup]
-> Const (First [ClusterSubnetGroup]) [ClusterSubnetGroup])
-> Maybe [ClusterSubnetGroup]
-> Const (First [ClusterSubnetGroup]) (Maybe [ClusterSubnetGroup]))
-> Getting
(First [ClusterSubnetGroup])
DescribeClusterSubnetGroupsResponse
[ClusterSubnetGroup]
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. ([ClusterSubnetGroup]
-> Const (First [ClusterSubnetGroup]) [ClusterSubnetGroup])
-> Maybe [ClusterSubnetGroup]
-> Const (First [ClusterSubnetGroup]) (Maybe [ClusterSubnetGroup])
forall a b. Prism (Maybe a) (Maybe b) a b
Lens._Just
) =
Maybe DescribeClusterSubnetGroups
forall a. Maybe a
Prelude.Nothing
| Bool
Prelude.otherwise =
DescribeClusterSubnetGroups -> Maybe DescribeClusterSubnetGroups
forall a. a -> Maybe a
Prelude.Just (DescribeClusterSubnetGroups -> Maybe DescribeClusterSubnetGroups)
-> DescribeClusterSubnetGroups -> Maybe DescribeClusterSubnetGroups
forall a b. (a -> b) -> a -> b
Prelude.$
DescribeClusterSubnetGroups
rq
DescribeClusterSubnetGroups
-> (DescribeClusterSubnetGroups -> DescribeClusterSubnetGroups)
-> DescribeClusterSubnetGroups
forall a b. a -> (a -> b) -> b
Prelude.& (Maybe Text -> Identity (Maybe Text))
-> DescribeClusterSubnetGroups
-> Identity DescribeClusterSubnetGroups
Lens
DescribeClusterSubnetGroups
DescribeClusterSubnetGroups
(Maybe Text)
(Maybe Text)
describeClusterSubnetGroups_marker
((Maybe Text -> Identity (Maybe Text))
-> DescribeClusterSubnetGroups
-> Identity DescribeClusterSubnetGroups)
-> Maybe Text
-> DescribeClusterSubnetGroups
-> DescribeClusterSubnetGroups
forall s t a b. ASetter s t a b -> b -> s -> t
Lens..~ AWSResponse DescribeClusterSubnetGroups
DescribeClusterSubnetGroupsResponse
rs
DescribeClusterSubnetGroupsResponse
-> Getting (First Text) DescribeClusterSubnetGroupsResponse Text
-> Maybe Text
forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? (Maybe Text -> Const (First Text) (Maybe Text))
-> DescribeClusterSubnetGroupsResponse
-> Const (First Text) DescribeClusterSubnetGroupsResponse
Lens' DescribeClusterSubnetGroupsResponse (Maybe Text)
describeClusterSubnetGroupsResponse_marker
((Maybe Text -> Const (First Text) (Maybe Text))
-> DescribeClusterSubnetGroupsResponse
-> Const (First Text) DescribeClusterSubnetGroupsResponse)
-> ((Text -> Const (First Text) Text)
-> Maybe Text -> Const (First Text) (Maybe Text))
-> Getting (First Text) DescribeClusterSubnetGroupsResponse 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 DescribeClusterSubnetGroups where
type
AWSResponse DescribeClusterSubnetGroups =
DescribeClusterSubnetGroupsResponse
request :: DescribeClusterSubnetGroups -> Request DescribeClusterSubnetGroups
request = Service
-> DescribeClusterSubnetGroups
-> Request DescribeClusterSubnetGroups
forall a. ToRequest a => Service -> a -> Request a
Request.postQuery Service
defaultService
response :: Logger
-> Service
-> Proxy DescribeClusterSubnetGroups
-> ClientResponse ClientBody
-> m (Either
Error (ClientResponse (AWSResponse DescribeClusterSubnetGroups)))
response =
Text
-> (Int
-> ResponseHeaders
-> [Node]
-> Either String (AWSResponse DescribeClusterSubnetGroups))
-> Logger
-> Service
-> Proxy DescribeClusterSubnetGroups
-> ClientResponse ClientBody
-> m (Either
Error (ClientResponse (AWSResponse DescribeClusterSubnetGroups)))
forall (m :: * -> *) a.
MonadResource m =>
Text
-> (Int
-> ResponseHeaders -> [Node] -> Either String (AWSResponse a))
-> Logger
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveXMLWrapper
Text
"DescribeClusterSubnetGroupsResult"
( \Int
s ResponseHeaders
h [Node]
x ->
Maybe [ClusterSubnetGroup]
-> Maybe Text -> Int -> DescribeClusterSubnetGroupsResponse
DescribeClusterSubnetGroupsResponse'
(Maybe [ClusterSubnetGroup]
-> Maybe Text -> Int -> DescribeClusterSubnetGroupsResponse)
-> Either String (Maybe [ClusterSubnetGroup])
-> Either
String (Maybe Text -> Int -> DescribeClusterSubnetGroupsResponse)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> ( [Node]
x [Node] -> Text -> Either String (Maybe [Node])
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"ClusterSubnetGroups"
Either String (Maybe [Node]) -> [Node] -> Either String [Node]
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ [Node]
forall a. Monoid a => a
Prelude.mempty
Either String [Node]
-> ([Node] -> Either String (Maybe [ClusterSubnetGroup]))
-> Either String (Maybe [ClusterSubnetGroup])
forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b
Prelude.>>= ([Node] -> Either String [ClusterSubnetGroup])
-> [Node] -> Either String (Maybe [ClusterSubnetGroup])
forall (f :: * -> *) a b.
Applicative f =>
([a] -> f b) -> [a] -> f (Maybe b)
Core.may (Text -> [Node] -> Either String [ClusterSubnetGroup]
forall a. FromXML a => Text -> [Node] -> Either String [a]
Core.parseXMLList Text
"ClusterSubnetGroup")
)
Either
String (Maybe Text -> Int -> DescribeClusterSubnetGroupsResponse)
-> Either String (Maybe Text)
-> Either String (Int -> DescribeClusterSubnetGroupsResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe Text)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"Marker")
Either String (Int -> DescribeClusterSubnetGroupsResponse)
-> Either String Int
-> Either String DescribeClusterSubnetGroupsResponse
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 DescribeClusterSubnetGroups
instance Prelude.NFData DescribeClusterSubnetGroups
instance Core.ToHeaders DescribeClusterSubnetGroups where
toHeaders :: DescribeClusterSubnetGroups -> ResponseHeaders
toHeaders = ResponseHeaders -> DescribeClusterSubnetGroups -> ResponseHeaders
forall a b. a -> b -> a
Prelude.const ResponseHeaders
forall a. Monoid a => a
Prelude.mempty
instance Core.ToPath DescribeClusterSubnetGroups where
toPath :: DescribeClusterSubnetGroups -> ByteString
toPath = ByteString -> DescribeClusterSubnetGroups -> ByteString
forall a b. a -> b -> a
Prelude.const ByteString
"/"
instance Core.ToQuery DescribeClusterSubnetGroups where
toQuery :: DescribeClusterSubnetGroups -> QueryString
toQuery DescribeClusterSubnetGroups' {Maybe Int
Maybe [Text]
Maybe Text
maxRecords :: Maybe Int
marker :: Maybe Text
clusterSubnetGroupName :: Maybe Text
tagKeys :: Maybe [Text]
tagValues :: Maybe [Text]
$sel:maxRecords:DescribeClusterSubnetGroups' :: DescribeClusterSubnetGroups -> Maybe Int
$sel:marker:DescribeClusterSubnetGroups' :: DescribeClusterSubnetGroups -> Maybe Text
$sel:clusterSubnetGroupName:DescribeClusterSubnetGroups' :: DescribeClusterSubnetGroups -> Maybe Text
$sel:tagKeys:DescribeClusterSubnetGroups' :: DescribeClusterSubnetGroups -> Maybe [Text]
$sel:tagValues:DescribeClusterSubnetGroups' :: DescribeClusterSubnetGroups -> Maybe [Text]
..} =
[QueryString] -> QueryString
forall a. Monoid a => [a] -> a
Prelude.mconcat
[ ByteString
"Action"
ByteString -> ByteString -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: ( ByteString
"DescribeClusterSubnetGroups" ::
Prelude.ByteString
),
ByteString
"Version"
ByteString -> ByteString -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: (ByteString
"2012-12-01" :: Prelude.ByteString),
ByteString
"TagValues"
ByteString -> QueryString -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: Maybe QueryString -> QueryString
forall a. ToQuery a => a -> QueryString
Core.toQuery
(ByteString -> [Text] -> QueryString
forall a.
(IsList a, ToQuery (Item a)) =>
ByteString -> a -> QueryString
Core.toQueryList ByteString
"TagValue" ([Text] -> QueryString) -> Maybe [Text] -> Maybe QueryString
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [Text]
tagValues),
ByteString
"TagKeys"
ByteString -> QueryString -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: Maybe QueryString -> QueryString
forall a. ToQuery a => a -> QueryString
Core.toQuery
(ByteString -> [Text] -> QueryString
forall a.
(IsList a, ToQuery (Item a)) =>
ByteString -> a -> QueryString
Core.toQueryList ByteString
"TagKey" ([Text] -> QueryString) -> Maybe [Text] -> Maybe QueryString
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [Text]
tagKeys),
ByteString
"ClusterSubnetGroupName"
ByteString -> Maybe Text -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: Maybe Text
clusterSubnetGroupName,
ByteString
"Marker" ByteString -> Maybe Text -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: Maybe Text
marker,
ByteString
"MaxRecords" ByteString -> Maybe Int -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: Maybe Int
maxRecords
]
data DescribeClusterSubnetGroupsResponse = DescribeClusterSubnetGroupsResponse'
{
DescribeClusterSubnetGroupsResponse -> Maybe [ClusterSubnetGroup]
clusterSubnetGroups :: Prelude.Maybe [ClusterSubnetGroup],
DescribeClusterSubnetGroupsResponse -> Maybe Text
marker :: Prelude.Maybe Prelude.Text,
DescribeClusterSubnetGroupsResponse -> Int
httpStatus :: Prelude.Int
}
deriving (DescribeClusterSubnetGroupsResponse
-> DescribeClusterSubnetGroupsResponse -> Bool
(DescribeClusterSubnetGroupsResponse
-> DescribeClusterSubnetGroupsResponse -> Bool)
-> (DescribeClusterSubnetGroupsResponse
-> DescribeClusterSubnetGroupsResponse -> Bool)
-> Eq DescribeClusterSubnetGroupsResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DescribeClusterSubnetGroupsResponse
-> DescribeClusterSubnetGroupsResponse -> Bool
$c/= :: DescribeClusterSubnetGroupsResponse
-> DescribeClusterSubnetGroupsResponse -> Bool
== :: DescribeClusterSubnetGroupsResponse
-> DescribeClusterSubnetGroupsResponse -> Bool
$c== :: DescribeClusterSubnetGroupsResponse
-> DescribeClusterSubnetGroupsResponse -> Bool
Prelude.Eq, ReadPrec [DescribeClusterSubnetGroupsResponse]
ReadPrec DescribeClusterSubnetGroupsResponse
Int -> ReadS DescribeClusterSubnetGroupsResponse
ReadS [DescribeClusterSubnetGroupsResponse]
(Int -> ReadS DescribeClusterSubnetGroupsResponse)
-> ReadS [DescribeClusterSubnetGroupsResponse]
-> ReadPrec DescribeClusterSubnetGroupsResponse
-> ReadPrec [DescribeClusterSubnetGroupsResponse]
-> Read DescribeClusterSubnetGroupsResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DescribeClusterSubnetGroupsResponse]
$creadListPrec :: ReadPrec [DescribeClusterSubnetGroupsResponse]
readPrec :: ReadPrec DescribeClusterSubnetGroupsResponse
$creadPrec :: ReadPrec DescribeClusterSubnetGroupsResponse
readList :: ReadS [DescribeClusterSubnetGroupsResponse]
$creadList :: ReadS [DescribeClusterSubnetGroupsResponse]
readsPrec :: Int -> ReadS DescribeClusterSubnetGroupsResponse
$creadsPrec :: Int -> ReadS DescribeClusterSubnetGroupsResponse
Prelude.Read, Int -> DescribeClusterSubnetGroupsResponse -> ShowS
[DescribeClusterSubnetGroupsResponse] -> ShowS
DescribeClusterSubnetGroupsResponse -> String
(Int -> DescribeClusterSubnetGroupsResponse -> ShowS)
-> (DescribeClusterSubnetGroupsResponse -> String)
-> ([DescribeClusterSubnetGroupsResponse] -> ShowS)
-> Show DescribeClusterSubnetGroupsResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DescribeClusterSubnetGroupsResponse] -> ShowS
$cshowList :: [DescribeClusterSubnetGroupsResponse] -> ShowS
show :: DescribeClusterSubnetGroupsResponse -> String
$cshow :: DescribeClusterSubnetGroupsResponse -> String
showsPrec :: Int -> DescribeClusterSubnetGroupsResponse -> ShowS
$cshowsPrec :: Int -> DescribeClusterSubnetGroupsResponse -> ShowS
Prelude.Show, (forall x.
DescribeClusterSubnetGroupsResponse
-> Rep DescribeClusterSubnetGroupsResponse x)
-> (forall x.
Rep DescribeClusterSubnetGroupsResponse x
-> DescribeClusterSubnetGroupsResponse)
-> Generic DescribeClusterSubnetGroupsResponse
forall x.
Rep DescribeClusterSubnetGroupsResponse x
-> DescribeClusterSubnetGroupsResponse
forall x.
DescribeClusterSubnetGroupsResponse
-> Rep DescribeClusterSubnetGroupsResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep DescribeClusterSubnetGroupsResponse x
-> DescribeClusterSubnetGroupsResponse
$cfrom :: forall x.
DescribeClusterSubnetGroupsResponse
-> Rep DescribeClusterSubnetGroupsResponse x
Prelude.Generic)
newDescribeClusterSubnetGroupsResponse ::
Prelude.Int ->
DescribeClusterSubnetGroupsResponse
newDescribeClusterSubnetGroupsResponse :: Int -> DescribeClusterSubnetGroupsResponse
newDescribeClusterSubnetGroupsResponse Int
pHttpStatus_ =
DescribeClusterSubnetGroupsResponse' :: Maybe [ClusterSubnetGroup]
-> Maybe Text -> Int -> DescribeClusterSubnetGroupsResponse
DescribeClusterSubnetGroupsResponse'
{ $sel:clusterSubnetGroups:DescribeClusterSubnetGroupsResponse' :: Maybe [ClusterSubnetGroup]
clusterSubnetGroups =
Maybe [ClusterSubnetGroup]
forall a. Maybe a
Prelude.Nothing,
$sel:marker:DescribeClusterSubnetGroupsResponse' :: Maybe Text
marker = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:httpStatus:DescribeClusterSubnetGroupsResponse' :: Int
httpStatus = Int
pHttpStatus_
}
describeClusterSubnetGroupsResponse_clusterSubnetGroups :: Lens.Lens' DescribeClusterSubnetGroupsResponse (Prelude.Maybe [ClusterSubnetGroup])
describeClusterSubnetGroupsResponse_clusterSubnetGroups :: (Maybe [ClusterSubnetGroup] -> f (Maybe [ClusterSubnetGroup]))
-> DescribeClusterSubnetGroupsResponse
-> f DescribeClusterSubnetGroupsResponse
describeClusterSubnetGroupsResponse_clusterSubnetGroups = (DescribeClusterSubnetGroupsResponse -> Maybe [ClusterSubnetGroup])
-> (DescribeClusterSubnetGroupsResponse
-> Maybe [ClusterSubnetGroup]
-> DescribeClusterSubnetGroupsResponse)
-> Lens'
DescribeClusterSubnetGroupsResponse (Maybe [ClusterSubnetGroup])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeClusterSubnetGroupsResponse' {Maybe [ClusterSubnetGroup]
clusterSubnetGroups :: Maybe [ClusterSubnetGroup]
$sel:clusterSubnetGroups:DescribeClusterSubnetGroupsResponse' :: DescribeClusterSubnetGroupsResponse -> Maybe [ClusterSubnetGroup]
clusterSubnetGroups} -> Maybe [ClusterSubnetGroup]
clusterSubnetGroups) (\s :: DescribeClusterSubnetGroupsResponse
s@DescribeClusterSubnetGroupsResponse' {} Maybe [ClusterSubnetGroup]
a -> DescribeClusterSubnetGroupsResponse
s {$sel:clusterSubnetGroups:DescribeClusterSubnetGroupsResponse' :: Maybe [ClusterSubnetGroup]
clusterSubnetGroups = Maybe [ClusterSubnetGroup]
a} :: DescribeClusterSubnetGroupsResponse) ((Maybe [ClusterSubnetGroup] -> f (Maybe [ClusterSubnetGroup]))
-> DescribeClusterSubnetGroupsResponse
-> f DescribeClusterSubnetGroupsResponse)
-> ((Maybe [ClusterSubnetGroup] -> f (Maybe [ClusterSubnetGroup]))
-> Maybe [ClusterSubnetGroup] -> f (Maybe [ClusterSubnetGroup]))
-> (Maybe [ClusterSubnetGroup] -> f (Maybe [ClusterSubnetGroup]))
-> DescribeClusterSubnetGroupsResponse
-> f DescribeClusterSubnetGroupsResponse
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
[ClusterSubnetGroup]
[ClusterSubnetGroup]
[ClusterSubnetGroup]
[ClusterSubnetGroup]
-> Iso
(Maybe [ClusterSubnetGroup])
(Maybe [ClusterSubnetGroup])
(Maybe [ClusterSubnetGroup])
(Maybe [ClusterSubnetGroup])
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
[ClusterSubnetGroup]
[ClusterSubnetGroup]
[ClusterSubnetGroup]
[ClusterSubnetGroup]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
describeClusterSubnetGroupsResponse_marker :: Lens.Lens' DescribeClusterSubnetGroupsResponse (Prelude.Maybe Prelude.Text)
describeClusterSubnetGroupsResponse_marker :: (Maybe Text -> f (Maybe Text))
-> DescribeClusterSubnetGroupsResponse
-> f DescribeClusterSubnetGroupsResponse
describeClusterSubnetGroupsResponse_marker = (DescribeClusterSubnetGroupsResponse -> Maybe Text)
-> (DescribeClusterSubnetGroupsResponse
-> Maybe Text -> DescribeClusterSubnetGroupsResponse)
-> Lens' DescribeClusterSubnetGroupsResponse (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeClusterSubnetGroupsResponse' {Maybe Text
marker :: Maybe Text
$sel:marker:DescribeClusterSubnetGroupsResponse' :: DescribeClusterSubnetGroupsResponse -> Maybe Text
marker} -> Maybe Text
marker) (\s :: DescribeClusterSubnetGroupsResponse
s@DescribeClusterSubnetGroupsResponse' {} Maybe Text
a -> DescribeClusterSubnetGroupsResponse
s {$sel:marker:DescribeClusterSubnetGroupsResponse' :: Maybe Text
marker = Maybe Text
a} :: DescribeClusterSubnetGroupsResponse)
describeClusterSubnetGroupsResponse_httpStatus :: Lens.Lens' DescribeClusterSubnetGroupsResponse Prelude.Int
describeClusterSubnetGroupsResponse_httpStatus :: (Int -> f Int)
-> DescribeClusterSubnetGroupsResponse
-> f DescribeClusterSubnetGroupsResponse
describeClusterSubnetGroupsResponse_httpStatus = (DescribeClusterSubnetGroupsResponse -> Int)
-> (DescribeClusterSubnetGroupsResponse
-> Int -> DescribeClusterSubnetGroupsResponse)
-> Lens
DescribeClusterSubnetGroupsResponse
DescribeClusterSubnetGroupsResponse
Int
Int
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeClusterSubnetGroupsResponse' {Int
httpStatus :: Int
$sel:httpStatus:DescribeClusterSubnetGroupsResponse' :: DescribeClusterSubnetGroupsResponse -> Int
httpStatus} -> Int
httpStatus) (\s :: DescribeClusterSubnetGroupsResponse
s@DescribeClusterSubnetGroupsResponse' {} Int
a -> DescribeClusterSubnetGroupsResponse
s {$sel:httpStatus:DescribeClusterSubnetGroupsResponse' :: Int
httpStatus = Int
a} :: DescribeClusterSubnetGroupsResponse)
instance
Prelude.NFData
DescribeClusterSubnetGroupsResponse