{-# 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.AWSHealth.DescribeEventTypes
(
DescribeEventTypes (..),
newDescribeEventTypes,
describeEventTypes_locale,
describeEventTypes_nextToken,
describeEventTypes_filter,
describeEventTypes_maxResults,
DescribeEventTypesResponse (..),
newDescribeEventTypesResponse,
describeEventTypesResponse_eventTypes,
describeEventTypesResponse_nextToken,
describeEventTypesResponse_httpStatus,
)
where
import Amazonka.AWSHealth.Types
import qualified Amazonka.Core as Core
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 DescribeEventTypes = DescribeEventTypes'
{
DescribeEventTypes -> Maybe Text
locale :: Prelude.Maybe Prelude.Text,
DescribeEventTypes -> Maybe Text
nextToken :: Prelude.Maybe Prelude.Text,
DescribeEventTypes -> Maybe EventTypeFilter
filter' :: Prelude.Maybe EventTypeFilter,
DescribeEventTypes -> Maybe Natural
maxResults :: Prelude.Maybe Prelude.Natural
}
deriving (DescribeEventTypes -> DescribeEventTypes -> Bool
(DescribeEventTypes -> DescribeEventTypes -> Bool)
-> (DescribeEventTypes -> DescribeEventTypes -> Bool)
-> Eq DescribeEventTypes
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DescribeEventTypes -> DescribeEventTypes -> Bool
$c/= :: DescribeEventTypes -> DescribeEventTypes -> Bool
== :: DescribeEventTypes -> DescribeEventTypes -> Bool
$c== :: DescribeEventTypes -> DescribeEventTypes -> Bool
Prelude.Eq, ReadPrec [DescribeEventTypes]
ReadPrec DescribeEventTypes
Int -> ReadS DescribeEventTypes
ReadS [DescribeEventTypes]
(Int -> ReadS DescribeEventTypes)
-> ReadS [DescribeEventTypes]
-> ReadPrec DescribeEventTypes
-> ReadPrec [DescribeEventTypes]
-> Read DescribeEventTypes
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DescribeEventTypes]
$creadListPrec :: ReadPrec [DescribeEventTypes]
readPrec :: ReadPrec DescribeEventTypes
$creadPrec :: ReadPrec DescribeEventTypes
readList :: ReadS [DescribeEventTypes]
$creadList :: ReadS [DescribeEventTypes]
readsPrec :: Int -> ReadS DescribeEventTypes
$creadsPrec :: Int -> ReadS DescribeEventTypes
Prelude.Read, Int -> DescribeEventTypes -> ShowS
[DescribeEventTypes] -> ShowS
DescribeEventTypes -> String
(Int -> DescribeEventTypes -> ShowS)
-> (DescribeEventTypes -> String)
-> ([DescribeEventTypes] -> ShowS)
-> Show DescribeEventTypes
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DescribeEventTypes] -> ShowS
$cshowList :: [DescribeEventTypes] -> ShowS
show :: DescribeEventTypes -> String
$cshow :: DescribeEventTypes -> String
showsPrec :: Int -> DescribeEventTypes -> ShowS
$cshowsPrec :: Int -> DescribeEventTypes -> ShowS
Prelude.Show, (forall x. DescribeEventTypes -> Rep DescribeEventTypes x)
-> (forall x. Rep DescribeEventTypes x -> DescribeEventTypes)
-> Generic DescribeEventTypes
forall x. Rep DescribeEventTypes x -> DescribeEventTypes
forall x. DescribeEventTypes -> Rep DescribeEventTypes x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep DescribeEventTypes x -> DescribeEventTypes
$cfrom :: forall x. DescribeEventTypes -> Rep DescribeEventTypes x
Prelude.Generic)
newDescribeEventTypes ::
DescribeEventTypes
newDescribeEventTypes :: DescribeEventTypes
newDescribeEventTypes =
DescribeEventTypes' :: Maybe Text
-> Maybe Text
-> Maybe EventTypeFilter
-> Maybe Natural
-> DescribeEventTypes
DescribeEventTypes'
{ $sel:locale:DescribeEventTypes' :: Maybe Text
locale = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:nextToken:DescribeEventTypes' :: Maybe Text
nextToken = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:filter':DescribeEventTypes' :: Maybe EventTypeFilter
filter' = Maybe EventTypeFilter
forall a. Maybe a
Prelude.Nothing,
$sel:maxResults:DescribeEventTypes' :: Maybe Natural
maxResults = Maybe Natural
forall a. Maybe a
Prelude.Nothing
}
describeEventTypes_locale :: Lens.Lens' DescribeEventTypes (Prelude.Maybe Prelude.Text)
describeEventTypes_locale :: (Maybe Text -> f (Maybe Text))
-> DescribeEventTypes -> f DescribeEventTypes
describeEventTypes_locale = (DescribeEventTypes -> Maybe Text)
-> (DescribeEventTypes -> Maybe Text -> DescribeEventTypes)
-> Lens
DescribeEventTypes DescribeEventTypes (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeEventTypes' {Maybe Text
locale :: Maybe Text
$sel:locale:DescribeEventTypes' :: DescribeEventTypes -> Maybe Text
locale} -> Maybe Text
locale) (\s :: DescribeEventTypes
s@DescribeEventTypes' {} Maybe Text
a -> DescribeEventTypes
s {$sel:locale:DescribeEventTypes' :: Maybe Text
locale = Maybe Text
a} :: DescribeEventTypes)
describeEventTypes_nextToken :: Lens.Lens' DescribeEventTypes (Prelude.Maybe Prelude.Text)
describeEventTypes_nextToken :: (Maybe Text -> f (Maybe Text))
-> DescribeEventTypes -> f DescribeEventTypes
describeEventTypes_nextToken = (DescribeEventTypes -> Maybe Text)
-> (DescribeEventTypes -> Maybe Text -> DescribeEventTypes)
-> Lens
DescribeEventTypes DescribeEventTypes (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeEventTypes' {Maybe Text
nextToken :: Maybe Text
$sel:nextToken:DescribeEventTypes' :: DescribeEventTypes -> Maybe Text
nextToken} -> Maybe Text
nextToken) (\s :: DescribeEventTypes
s@DescribeEventTypes' {} Maybe Text
a -> DescribeEventTypes
s {$sel:nextToken:DescribeEventTypes' :: Maybe Text
nextToken = Maybe Text
a} :: DescribeEventTypes)
describeEventTypes_filter :: Lens.Lens' DescribeEventTypes (Prelude.Maybe EventTypeFilter)
describeEventTypes_filter :: (Maybe EventTypeFilter -> f (Maybe EventTypeFilter))
-> DescribeEventTypes -> f DescribeEventTypes
describeEventTypes_filter = (DescribeEventTypes -> Maybe EventTypeFilter)
-> (DescribeEventTypes
-> Maybe EventTypeFilter -> DescribeEventTypes)
-> Lens
DescribeEventTypes
DescribeEventTypes
(Maybe EventTypeFilter)
(Maybe EventTypeFilter)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeEventTypes' {Maybe EventTypeFilter
filter' :: Maybe EventTypeFilter
$sel:filter':DescribeEventTypes' :: DescribeEventTypes -> Maybe EventTypeFilter
filter'} -> Maybe EventTypeFilter
filter') (\s :: DescribeEventTypes
s@DescribeEventTypes' {} Maybe EventTypeFilter
a -> DescribeEventTypes
s {$sel:filter':DescribeEventTypes' :: Maybe EventTypeFilter
filter' = Maybe EventTypeFilter
a} :: DescribeEventTypes)
describeEventTypes_maxResults :: Lens.Lens' DescribeEventTypes (Prelude.Maybe Prelude.Natural)
describeEventTypes_maxResults :: (Maybe Natural -> f (Maybe Natural))
-> DescribeEventTypes -> f DescribeEventTypes
describeEventTypes_maxResults = (DescribeEventTypes -> Maybe Natural)
-> (DescribeEventTypes -> Maybe Natural -> DescribeEventTypes)
-> Lens
DescribeEventTypes
DescribeEventTypes
(Maybe Natural)
(Maybe Natural)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeEventTypes' {Maybe Natural
maxResults :: Maybe Natural
$sel:maxResults:DescribeEventTypes' :: DescribeEventTypes -> Maybe Natural
maxResults} -> Maybe Natural
maxResults) (\s :: DescribeEventTypes
s@DescribeEventTypes' {} Maybe Natural
a -> DescribeEventTypes
s {$sel:maxResults:DescribeEventTypes' :: Maybe Natural
maxResults = Maybe Natural
a} :: DescribeEventTypes)
instance Core.AWSPager DescribeEventTypes where
page :: DescribeEventTypes
-> AWSResponse DescribeEventTypes -> Maybe DescribeEventTypes
page DescribeEventTypes
rq AWSResponse DescribeEventTypes
rs
| Maybe Text -> Bool
forall a. AWSTruncated a => a -> Bool
Core.stop
( AWSResponse DescribeEventTypes
DescribeEventTypesResponse
rs
DescribeEventTypesResponse
-> Getting (First Text) DescribeEventTypesResponse Text
-> Maybe Text
forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? (Maybe Text -> Const (First Text) (Maybe Text))
-> DescribeEventTypesResponse
-> Const (First Text) DescribeEventTypesResponse
Lens' DescribeEventTypesResponse (Maybe Text)
describeEventTypesResponse_nextToken
((Maybe Text -> Const (First Text) (Maybe Text))
-> DescribeEventTypesResponse
-> Const (First Text) DescribeEventTypesResponse)
-> ((Text -> Const (First Text) Text)
-> Maybe Text -> Const (First Text) (Maybe Text))
-> Getting (First Text) DescribeEventTypesResponse 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 DescribeEventTypes
forall a. Maybe a
Prelude.Nothing
| Maybe [EventType] -> Bool
forall a. AWSTruncated a => a -> Bool
Core.stop
( AWSResponse DescribeEventTypes
DescribeEventTypesResponse
rs
DescribeEventTypesResponse
-> Getting
(First [EventType]) DescribeEventTypesResponse [EventType]
-> Maybe [EventType]
forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? (Maybe [EventType]
-> Const (First [EventType]) (Maybe [EventType]))
-> DescribeEventTypesResponse
-> Const (First [EventType]) DescribeEventTypesResponse
Lens' DescribeEventTypesResponse (Maybe [EventType])
describeEventTypesResponse_eventTypes
((Maybe [EventType]
-> Const (First [EventType]) (Maybe [EventType]))
-> DescribeEventTypesResponse
-> Const (First [EventType]) DescribeEventTypesResponse)
-> (([EventType] -> Const (First [EventType]) [EventType])
-> Maybe [EventType]
-> Const (First [EventType]) (Maybe [EventType]))
-> Getting
(First [EventType]) DescribeEventTypesResponse [EventType]
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. ([EventType] -> Const (First [EventType]) [EventType])
-> Maybe [EventType]
-> Const (First [EventType]) (Maybe [EventType])
forall a b. Prism (Maybe a) (Maybe b) a b
Lens._Just
) =
Maybe DescribeEventTypes
forall a. Maybe a
Prelude.Nothing
| Bool
Prelude.otherwise =
DescribeEventTypes -> Maybe DescribeEventTypes
forall a. a -> Maybe a
Prelude.Just (DescribeEventTypes -> Maybe DescribeEventTypes)
-> DescribeEventTypes -> Maybe DescribeEventTypes
forall a b. (a -> b) -> a -> b
Prelude.$
DescribeEventTypes
rq
DescribeEventTypes
-> (DescribeEventTypes -> DescribeEventTypes) -> DescribeEventTypes
forall a b. a -> (a -> b) -> b
Prelude.& (Maybe Text -> Identity (Maybe Text))
-> DescribeEventTypes -> Identity DescribeEventTypes
Lens
DescribeEventTypes DescribeEventTypes (Maybe Text) (Maybe Text)
describeEventTypes_nextToken
((Maybe Text -> Identity (Maybe Text))
-> DescribeEventTypes -> Identity DescribeEventTypes)
-> Maybe Text -> DescribeEventTypes -> DescribeEventTypes
forall s t a b. ASetter s t a b -> b -> s -> t
Lens..~ AWSResponse DescribeEventTypes
DescribeEventTypesResponse
rs
DescribeEventTypesResponse
-> Getting (First Text) DescribeEventTypesResponse Text
-> Maybe Text
forall s a. s -> Getting (First a) s a -> Maybe a
Lens.^? (Maybe Text -> Const (First Text) (Maybe Text))
-> DescribeEventTypesResponse
-> Const (First Text) DescribeEventTypesResponse
Lens' DescribeEventTypesResponse (Maybe Text)
describeEventTypesResponse_nextToken
((Maybe Text -> Const (First Text) (Maybe Text))
-> DescribeEventTypesResponse
-> Const (First Text) DescribeEventTypesResponse)
-> ((Text -> Const (First Text) Text)
-> Maybe Text -> Const (First Text) (Maybe Text))
-> Getting (First Text) DescribeEventTypesResponse 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 DescribeEventTypes where
type
AWSResponse DescribeEventTypes =
DescribeEventTypesResponse
request :: DescribeEventTypes -> Request DescribeEventTypes
request = Service -> DescribeEventTypes -> Request DescribeEventTypes
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.postJSON Service
defaultService
response :: Logger
-> Service
-> Proxy DescribeEventTypes
-> ClientResponse ClientBody
-> m (Either
Error (ClientResponse (AWSResponse DescribeEventTypes)))
response =
(Int
-> ResponseHeaders
-> Object
-> Either String (AWSResponse DescribeEventTypes))
-> Logger
-> Service
-> Proxy DescribeEventTypes
-> ClientResponse ClientBody
-> m (Either
Error (ClientResponse (AWSResponse DescribeEventTypes)))
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 [EventType]
-> Maybe Text -> Int -> DescribeEventTypesResponse
DescribeEventTypesResponse'
(Maybe [EventType]
-> Maybe Text -> Int -> DescribeEventTypesResponse)
-> Either String (Maybe [EventType])
-> Either String (Maybe Text -> Int -> DescribeEventTypesResponse)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Either String (Maybe (Maybe [EventType]))
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"eventTypes" Either String (Maybe (Maybe [EventType]))
-> Maybe [EventType] -> Either String (Maybe [EventType])
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ Maybe [EventType]
forall a. Monoid a => a
Prelude.mempty)
Either String (Maybe Text -> Int -> DescribeEventTypesResponse)
-> Either String (Maybe Text)
-> Either String (Int -> DescribeEventTypesResponse)
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 -> DescribeEventTypesResponse)
-> Either String Int -> Either String DescribeEventTypesResponse
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 DescribeEventTypes
instance Prelude.NFData DescribeEventTypes
instance Core.ToHeaders DescribeEventTypes where
toHeaders :: DescribeEventTypes -> ResponseHeaders
toHeaders =
ResponseHeaders -> DescribeEventTypes -> 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
"AWSHealth_20160804.DescribeEventTypes" ::
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 DescribeEventTypes where
toJSON :: DescribeEventTypes -> Value
toJSON DescribeEventTypes' {Maybe Natural
Maybe Text
Maybe EventTypeFilter
maxResults :: Maybe Natural
filter' :: Maybe EventTypeFilter
nextToken :: Maybe Text
locale :: Maybe Text
$sel:maxResults:DescribeEventTypes' :: DescribeEventTypes -> Maybe Natural
$sel:filter':DescribeEventTypes' :: DescribeEventTypes -> Maybe EventTypeFilter
$sel:nextToken:DescribeEventTypes' :: DescribeEventTypes -> Maybe Text
$sel:locale:DescribeEventTypes' :: DescribeEventTypes -> Maybe Text
..} =
[Pair] -> Value
Core.object
( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[ (Text
"locale" 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
locale,
(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
"filter" Text -> EventTypeFilter -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (EventTypeFilter -> Pair) -> Maybe EventTypeFilter -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe EventTypeFilter
filter',
(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 DescribeEventTypes where
toPath :: DescribeEventTypes -> ByteString
toPath = ByteString -> DescribeEventTypes -> ByteString
forall a b. a -> b -> a
Prelude.const ByteString
"/"
instance Core.ToQuery DescribeEventTypes where
toQuery :: DescribeEventTypes -> QueryString
toQuery = QueryString -> DescribeEventTypes -> QueryString
forall a b. a -> b -> a
Prelude.const QueryString
forall a. Monoid a => a
Prelude.mempty
data DescribeEventTypesResponse = DescribeEventTypesResponse'
{
DescribeEventTypesResponse -> Maybe [EventType]
eventTypes :: Prelude.Maybe [EventType],
DescribeEventTypesResponse -> Maybe Text
nextToken :: Prelude.Maybe Prelude.Text,
DescribeEventTypesResponse -> Int
httpStatus :: Prelude.Int
}
deriving (DescribeEventTypesResponse -> DescribeEventTypesResponse -> Bool
(DescribeEventTypesResponse -> DescribeEventTypesResponse -> Bool)
-> (DescribeEventTypesResponse
-> DescribeEventTypesResponse -> Bool)
-> Eq DescribeEventTypesResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DescribeEventTypesResponse -> DescribeEventTypesResponse -> Bool
$c/= :: DescribeEventTypesResponse -> DescribeEventTypesResponse -> Bool
== :: DescribeEventTypesResponse -> DescribeEventTypesResponse -> Bool
$c== :: DescribeEventTypesResponse -> DescribeEventTypesResponse -> Bool
Prelude.Eq, ReadPrec [DescribeEventTypesResponse]
ReadPrec DescribeEventTypesResponse
Int -> ReadS DescribeEventTypesResponse
ReadS [DescribeEventTypesResponse]
(Int -> ReadS DescribeEventTypesResponse)
-> ReadS [DescribeEventTypesResponse]
-> ReadPrec DescribeEventTypesResponse
-> ReadPrec [DescribeEventTypesResponse]
-> Read DescribeEventTypesResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DescribeEventTypesResponse]
$creadListPrec :: ReadPrec [DescribeEventTypesResponse]
readPrec :: ReadPrec DescribeEventTypesResponse
$creadPrec :: ReadPrec DescribeEventTypesResponse
readList :: ReadS [DescribeEventTypesResponse]
$creadList :: ReadS [DescribeEventTypesResponse]
readsPrec :: Int -> ReadS DescribeEventTypesResponse
$creadsPrec :: Int -> ReadS DescribeEventTypesResponse
Prelude.Read, Int -> DescribeEventTypesResponse -> ShowS
[DescribeEventTypesResponse] -> ShowS
DescribeEventTypesResponse -> String
(Int -> DescribeEventTypesResponse -> ShowS)
-> (DescribeEventTypesResponse -> String)
-> ([DescribeEventTypesResponse] -> ShowS)
-> Show DescribeEventTypesResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DescribeEventTypesResponse] -> ShowS
$cshowList :: [DescribeEventTypesResponse] -> ShowS
show :: DescribeEventTypesResponse -> String
$cshow :: DescribeEventTypesResponse -> String
showsPrec :: Int -> DescribeEventTypesResponse -> ShowS
$cshowsPrec :: Int -> DescribeEventTypesResponse -> ShowS
Prelude.Show, (forall x.
DescribeEventTypesResponse -> Rep DescribeEventTypesResponse x)
-> (forall x.
Rep DescribeEventTypesResponse x -> DescribeEventTypesResponse)
-> Generic DescribeEventTypesResponse
forall x.
Rep DescribeEventTypesResponse x -> DescribeEventTypesResponse
forall x.
DescribeEventTypesResponse -> Rep DescribeEventTypesResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep DescribeEventTypesResponse x -> DescribeEventTypesResponse
$cfrom :: forall x.
DescribeEventTypesResponse -> Rep DescribeEventTypesResponse x
Prelude.Generic)
newDescribeEventTypesResponse ::
Prelude.Int ->
DescribeEventTypesResponse
newDescribeEventTypesResponse :: Int -> DescribeEventTypesResponse
newDescribeEventTypesResponse Int
pHttpStatus_ =
DescribeEventTypesResponse' :: Maybe [EventType]
-> Maybe Text -> Int -> DescribeEventTypesResponse
DescribeEventTypesResponse'
{ $sel:eventTypes:DescribeEventTypesResponse' :: Maybe [EventType]
eventTypes =
Maybe [EventType]
forall a. Maybe a
Prelude.Nothing,
$sel:nextToken:DescribeEventTypesResponse' :: Maybe Text
nextToken = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:httpStatus:DescribeEventTypesResponse' :: Int
httpStatus = Int
pHttpStatus_
}
describeEventTypesResponse_eventTypes :: Lens.Lens' DescribeEventTypesResponse (Prelude.Maybe [EventType])
describeEventTypesResponse_eventTypes :: (Maybe [EventType] -> f (Maybe [EventType]))
-> DescribeEventTypesResponse -> f DescribeEventTypesResponse
describeEventTypesResponse_eventTypes = (DescribeEventTypesResponse -> Maybe [EventType])
-> (DescribeEventTypesResponse
-> Maybe [EventType] -> DescribeEventTypesResponse)
-> Lens' DescribeEventTypesResponse (Maybe [EventType])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeEventTypesResponse' {Maybe [EventType]
eventTypes :: Maybe [EventType]
$sel:eventTypes:DescribeEventTypesResponse' :: DescribeEventTypesResponse -> Maybe [EventType]
eventTypes} -> Maybe [EventType]
eventTypes) (\s :: DescribeEventTypesResponse
s@DescribeEventTypesResponse' {} Maybe [EventType]
a -> DescribeEventTypesResponse
s {$sel:eventTypes:DescribeEventTypesResponse' :: Maybe [EventType]
eventTypes = Maybe [EventType]
a} :: DescribeEventTypesResponse) ((Maybe [EventType] -> f (Maybe [EventType]))
-> DescribeEventTypesResponse -> f DescribeEventTypesResponse)
-> ((Maybe [EventType] -> f (Maybe [EventType]))
-> Maybe [EventType] -> f (Maybe [EventType]))
-> (Maybe [EventType] -> f (Maybe [EventType]))
-> DescribeEventTypesResponse
-> f DescribeEventTypesResponse
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso [EventType] [EventType] [EventType] [EventType]
-> Iso
(Maybe [EventType])
(Maybe [EventType])
(Maybe [EventType])
(Maybe [EventType])
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 [EventType] [EventType] [EventType] [EventType]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
describeEventTypesResponse_nextToken :: Lens.Lens' DescribeEventTypesResponse (Prelude.Maybe Prelude.Text)
describeEventTypesResponse_nextToken :: (Maybe Text -> f (Maybe Text))
-> DescribeEventTypesResponse -> f DescribeEventTypesResponse
describeEventTypesResponse_nextToken = (DescribeEventTypesResponse -> Maybe Text)
-> (DescribeEventTypesResponse
-> Maybe Text -> DescribeEventTypesResponse)
-> Lens' DescribeEventTypesResponse (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeEventTypesResponse' {Maybe Text
nextToken :: Maybe Text
$sel:nextToken:DescribeEventTypesResponse' :: DescribeEventTypesResponse -> Maybe Text
nextToken} -> Maybe Text
nextToken) (\s :: DescribeEventTypesResponse
s@DescribeEventTypesResponse' {} Maybe Text
a -> DescribeEventTypesResponse
s {$sel:nextToken:DescribeEventTypesResponse' :: Maybe Text
nextToken = Maybe Text
a} :: DescribeEventTypesResponse)
describeEventTypesResponse_httpStatus :: Lens.Lens' DescribeEventTypesResponse Prelude.Int
describeEventTypesResponse_httpStatus :: (Int -> f Int)
-> DescribeEventTypesResponse -> f DescribeEventTypesResponse
describeEventTypesResponse_httpStatus = (DescribeEventTypesResponse -> Int)
-> (DescribeEventTypesResponse
-> Int -> DescribeEventTypesResponse)
-> Lens
DescribeEventTypesResponse DescribeEventTypesResponse Int Int
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeEventTypesResponse' {Int
httpStatus :: Int
$sel:httpStatus:DescribeEventTypesResponse' :: DescribeEventTypesResponse -> Int
httpStatus} -> Int
httpStatus) (\s :: DescribeEventTypesResponse
s@DescribeEventTypesResponse' {} Int
a -> DescribeEventTypesResponse
s {$sel:httpStatus:DescribeEventTypesResponse' :: Int
httpStatus = Int
a} :: DescribeEventTypesResponse)
instance Prelude.NFData DescribeEventTypesResponse