{-# 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.PinpointSmsVoiceV2.UpdateEventDestination
(
UpdateEventDestination (..),
newUpdateEventDestination,
updateEventDestination_cloudWatchLogsDestination,
updateEventDestination_enabled,
updateEventDestination_kinesisFirehoseDestination,
updateEventDestination_matchingEventTypes,
updateEventDestination_snsDestination,
updateEventDestination_configurationSetName,
updateEventDestination_eventDestinationName,
UpdateEventDestinationResponse (..),
newUpdateEventDestinationResponse,
updateEventDestinationResponse_configurationSetArn,
updateEventDestinationResponse_configurationSetName,
updateEventDestinationResponse_eventDestination,
updateEventDestinationResponse_httpStatus,
)
where
import qualified Amazonka.Core as Core
import qualified Amazonka.Core.Lens.Internal as Lens
import qualified Amazonka.Data as Data
import Amazonka.PinpointSmsVoiceV2.Types
import qualified Amazonka.Prelude as Prelude
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response
data UpdateEventDestination = UpdateEventDestination'
{
UpdateEventDestination -> Maybe CloudWatchLogsDestination
cloudWatchLogsDestination :: Prelude.Maybe CloudWatchLogsDestination,
UpdateEventDestination -> Maybe Bool
enabled :: Prelude.Maybe Prelude.Bool,
UpdateEventDestination -> Maybe KinesisFirehoseDestination
kinesisFirehoseDestination :: Prelude.Maybe KinesisFirehoseDestination,
UpdateEventDestination -> Maybe (NonEmpty EventType)
matchingEventTypes :: Prelude.Maybe (Prelude.NonEmpty EventType),
UpdateEventDestination -> Maybe SnsDestination
snsDestination :: Prelude.Maybe SnsDestination,
UpdateEventDestination -> Text
configurationSetName :: Prelude.Text,
UpdateEventDestination -> Text
eventDestinationName :: Prelude.Text
}
deriving (UpdateEventDestination -> UpdateEventDestination -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: UpdateEventDestination -> UpdateEventDestination -> Bool
$c/= :: UpdateEventDestination -> UpdateEventDestination -> Bool
== :: UpdateEventDestination -> UpdateEventDestination -> Bool
$c== :: UpdateEventDestination -> UpdateEventDestination -> Bool
Prelude.Eq, ReadPrec [UpdateEventDestination]
ReadPrec UpdateEventDestination
Int -> ReadS UpdateEventDestination
ReadS [UpdateEventDestination]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [UpdateEventDestination]
$creadListPrec :: ReadPrec [UpdateEventDestination]
readPrec :: ReadPrec UpdateEventDestination
$creadPrec :: ReadPrec UpdateEventDestination
readList :: ReadS [UpdateEventDestination]
$creadList :: ReadS [UpdateEventDestination]
readsPrec :: Int -> ReadS UpdateEventDestination
$creadsPrec :: Int -> ReadS UpdateEventDestination
Prelude.Read, Int -> UpdateEventDestination -> ShowS
[UpdateEventDestination] -> ShowS
UpdateEventDestination -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [UpdateEventDestination] -> ShowS
$cshowList :: [UpdateEventDestination] -> ShowS
show :: UpdateEventDestination -> String
$cshow :: UpdateEventDestination -> String
showsPrec :: Int -> UpdateEventDestination -> ShowS
$cshowsPrec :: Int -> UpdateEventDestination -> ShowS
Prelude.Show, forall x. Rep UpdateEventDestination x -> UpdateEventDestination
forall x. UpdateEventDestination -> Rep UpdateEventDestination x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep UpdateEventDestination x -> UpdateEventDestination
$cfrom :: forall x. UpdateEventDestination -> Rep UpdateEventDestination x
Prelude.Generic)
newUpdateEventDestination ::
Prelude.Text ->
Prelude.Text ->
UpdateEventDestination
newUpdateEventDestination :: Text -> Text -> UpdateEventDestination
newUpdateEventDestination
Text
pConfigurationSetName_
Text
pEventDestinationName_ =
UpdateEventDestination'
{ $sel:cloudWatchLogsDestination:UpdateEventDestination' :: Maybe CloudWatchLogsDestination
cloudWatchLogsDestination =
forall a. Maybe a
Prelude.Nothing,
$sel:enabled:UpdateEventDestination' :: Maybe Bool
enabled = forall a. Maybe a
Prelude.Nothing,
$sel:kinesisFirehoseDestination:UpdateEventDestination' :: Maybe KinesisFirehoseDestination
kinesisFirehoseDestination = forall a. Maybe a
Prelude.Nothing,
$sel:matchingEventTypes:UpdateEventDestination' :: Maybe (NonEmpty EventType)
matchingEventTypes = forall a. Maybe a
Prelude.Nothing,
$sel:snsDestination:UpdateEventDestination' :: Maybe SnsDestination
snsDestination = forall a. Maybe a
Prelude.Nothing,
$sel:configurationSetName:UpdateEventDestination' :: Text
configurationSetName = Text
pConfigurationSetName_,
$sel:eventDestinationName:UpdateEventDestination' :: Text
eventDestinationName = Text
pEventDestinationName_
}
updateEventDestination_cloudWatchLogsDestination :: Lens.Lens' UpdateEventDestination (Prelude.Maybe CloudWatchLogsDestination)
updateEventDestination_cloudWatchLogsDestination :: Lens' UpdateEventDestination (Maybe CloudWatchLogsDestination)
updateEventDestination_cloudWatchLogsDestination = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateEventDestination' {Maybe CloudWatchLogsDestination
cloudWatchLogsDestination :: Maybe CloudWatchLogsDestination
$sel:cloudWatchLogsDestination:UpdateEventDestination' :: UpdateEventDestination -> Maybe CloudWatchLogsDestination
cloudWatchLogsDestination} -> Maybe CloudWatchLogsDestination
cloudWatchLogsDestination) (\s :: UpdateEventDestination
s@UpdateEventDestination' {} Maybe CloudWatchLogsDestination
a -> UpdateEventDestination
s {$sel:cloudWatchLogsDestination:UpdateEventDestination' :: Maybe CloudWatchLogsDestination
cloudWatchLogsDestination = Maybe CloudWatchLogsDestination
a} :: UpdateEventDestination)
updateEventDestination_enabled :: Lens.Lens' UpdateEventDestination (Prelude.Maybe Prelude.Bool)
updateEventDestination_enabled :: Lens' UpdateEventDestination (Maybe Bool)
updateEventDestination_enabled = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateEventDestination' {Maybe Bool
enabled :: Maybe Bool
$sel:enabled:UpdateEventDestination' :: UpdateEventDestination -> Maybe Bool
enabled} -> Maybe Bool
enabled) (\s :: UpdateEventDestination
s@UpdateEventDestination' {} Maybe Bool
a -> UpdateEventDestination
s {$sel:enabled:UpdateEventDestination' :: Maybe Bool
enabled = Maybe Bool
a} :: UpdateEventDestination)
updateEventDestination_kinesisFirehoseDestination :: Lens.Lens' UpdateEventDestination (Prelude.Maybe KinesisFirehoseDestination)
updateEventDestination_kinesisFirehoseDestination :: Lens' UpdateEventDestination (Maybe KinesisFirehoseDestination)
updateEventDestination_kinesisFirehoseDestination = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateEventDestination' {Maybe KinesisFirehoseDestination
kinesisFirehoseDestination :: Maybe KinesisFirehoseDestination
$sel:kinesisFirehoseDestination:UpdateEventDestination' :: UpdateEventDestination -> Maybe KinesisFirehoseDestination
kinesisFirehoseDestination} -> Maybe KinesisFirehoseDestination
kinesisFirehoseDestination) (\s :: UpdateEventDestination
s@UpdateEventDestination' {} Maybe KinesisFirehoseDestination
a -> UpdateEventDestination
s {$sel:kinesisFirehoseDestination:UpdateEventDestination' :: Maybe KinesisFirehoseDestination
kinesisFirehoseDestination = Maybe KinesisFirehoseDestination
a} :: UpdateEventDestination)
updateEventDestination_matchingEventTypes :: Lens.Lens' UpdateEventDestination (Prelude.Maybe (Prelude.NonEmpty EventType))
updateEventDestination_matchingEventTypes :: Lens' UpdateEventDestination (Maybe (NonEmpty EventType))
updateEventDestination_matchingEventTypes = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateEventDestination' {Maybe (NonEmpty EventType)
matchingEventTypes :: Maybe (NonEmpty EventType)
$sel:matchingEventTypes:UpdateEventDestination' :: UpdateEventDestination -> Maybe (NonEmpty EventType)
matchingEventTypes} -> Maybe (NonEmpty EventType)
matchingEventTypes) (\s :: UpdateEventDestination
s@UpdateEventDestination' {} Maybe (NonEmpty EventType)
a -> UpdateEventDestination
s {$sel:matchingEventTypes:UpdateEventDestination' :: Maybe (NonEmpty EventType)
matchingEventTypes = Maybe (NonEmpty EventType)
a} :: UpdateEventDestination) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. 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 forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
updateEventDestination_snsDestination :: Lens.Lens' UpdateEventDestination (Prelude.Maybe SnsDestination)
updateEventDestination_snsDestination :: Lens' UpdateEventDestination (Maybe SnsDestination)
updateEventDestination_snsDestination = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateEventDestination' {Maybe SnsDestination
snsDestination :: Maybe SnsDestination
$sel:snsDestination:UpdateEventDestination' :: UpdateEventDestination -> Maybe SnsDestination
snsDestination} -> Maybe SnsDestination
snsDestination) (\s :: UpdateEventDestination
s@UpdateEventDestination' {} Maybe SnsDestination
a -> UpdateEventDestination
s {$sel:snsDestination:UpdateEventDestination' :: Maybe SnsDestination
snsDestination = Maybe SnsDestination
a} :: UpdateEventDestination)
updateEventDestination_configurationSetName :: Lens.Lens' UpdateEventDestination Prelude.Text
updateEventDestination_configurationSetName :: Lens' UpdateEventDestination Text
updateEventDestination_configurationSetName = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateEventDestination' {Text
configurationSetName :: Text
$sel:configurationSetName:UpdateEventDestination' :: UpdateEventDestination -> Text
configurationSetName} -> Text
configurationSetName) (\s :: UpdateEventDestination
s@UpdateEventDestination' {} Text
a -> UpdateEventDestination
s {$sel:configurationSetName:UpdateEventDestination' :: Text
configurationSetName = Text
a} :: UpdateEventDestination)
updateEventDestination_eventDestinationName :: Lens.Lens' UpdateEventDestination Prelude.Text
updateEventDestination_eventDestinationName :: Lens' UpdateEventDestination Text
updateEventDestination_eventDestinationName = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateEventDestination' {Text
eventDestinationName :: Text
$sel:eventDestinationName:UpdateEventDestination' :: UpdateEventDestination -> Text
eventDestinationName} -> Text
eventDestinationName) (\s :: UpdateEventDestination
s@UpdateEventDestination' {} Text
a -> UpdateEventDestination
s {$sel:eventDestinationName:UpdateEventDestination' :: Text
eventDestinationName = Text
a} :: UpdateEventDestination)
instance Core.AWSRequest UpdateEventDestination where
type
AWSResponse UpdateEventDestination =
UpdateEventDestinationResponse
request :: (Service -> Service)
-> UpdateEventDestination -> Request UpdateEventDestination
request Service -> Service
overrides =
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.postJSON (Service -> Service
overrides Service
defaultService)
response :: forall (m :: * -> *).
MonadResource m =>
(ByteStringLazy -> IO ByteStringLazy)
-> Service
-> Proxy UpdateEventDestination
-> ClientResponse ClientBody
-> m (Either
Error (ClientResponse (AWSResponse UpdateEventDestination)))
response =
forall (m :: * -> *) a.
MonadResource m =>
(Int -> ResponseHeaders -> Object -> Either String (AWSResponse a))
-> (ByteStringLazy -> IO ByteStringLazy)
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveJSON
( \Int
s ResponseHeaders
h Object
x ->
Maybe Text
-> Maybe Text
-> Maybe EventDestination
-> Int
-> UpdateEventDestinationResponse
UpdateEventDestinationResponse'
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x forall a. FromJSON a => Object -> Key -> Either String (Maybe a)
Data..?> Key
"ConfigurationSetArn")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Either String (Maybe a)
Data..?> Key
"ConfigurationSetName")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Either String (Maybe a)
Data..?> Key
"EventDestination")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure (forall a. Enum a => a -> Int
Prelude.fromEnum Int
s))
)
instance Prelude.Hashable UpdateEventDestination where
hashWithSalt :: Int -> UpdateEventDestination -> Int
hashWithSalt Int
_salt UpdateEventDestination' {Maybe Bool
Maybe (NonEmpty EventType)
Maybe CloudWatchLogsDestination
Maybe KinesisFirehoseDestination
Maybe SnsDestination
Text
eventDestinationName :: Text
configurationSetName :: Text
snsDestination :: Maybe SnsDestination
matchingEventTypes :: Maybe (NonEmpty EventType)
kinesisFirehoseDestination :: Maybe KinesisFirehoseDestination
enabled :: Maybe Bool
cloudWatchLogsDestination :: Maybe CloudWatchLogsDestination
$sel:eventDestinationName:UpdateEventDestination' :: UpdateEventDestination -> Text
$sel:configurationSetName:UpdateEventDestination' :: UpdateEventDestination -> Text
$sel:snsDestination:UpdateEventDestination' :: UpdateEventDestination -> Maybe SnsDestination
$sel:matchingEventTypes:UpdateEventDestination' :: UpdateEventDestination -> Maybe (NonEmpty EventType)
$sel:kinesisFirehoseDestination:UpdateEventDestination' :: UpdateEventDestination -> Maybe KinesisFirehoseDestination
$sel:enabled:UpdateEventDestination' :: UpdateEventDestination -> Maybe Bool
$sel:cloudWatchLogsDestination:UpdateEventDestination' :: UpdateEventDestination -> Maybe CloudWatchLogsDestination
..} =
Int
_salt
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe CloudWatchLogsDestination
cloudWatchLogsDestination
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Bool
enabled
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe KinesisFirehoseDestination
kinesisFirehoseDestination
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe (NonEmpty EventType)
matchingEventTypes
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe SnsDestination
snsDestination
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
configurationSetName
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
eventDestinationName
instance Prelude.NFData UpdateEventDestination where
rnf :: UpdateEventDestination -> ()
rnf UpdateEventDestination' {Maybe Bool
Maybe (NonEmpty EventType)
Maybe CloudWatchLogsDestination
Maybe KinesisFirehoseDestination
Maybe SnsDestination
Text
eventDestinationName :: Text
configurationSetName :: Text
snsDestination :: Maybe SnsDestination
matchingEventTypes :: Maybe (NonEmpty EventType)
kinesisFirehoseDestination :: Maybe KinesisFirehoseDestination
enabled :: Maybe Bool
cloudWatchLogsDestination :: Maybe CloudWatchLogsDestination
$sel:eventDestinationName:UpdateEventDestination' :: UpdateEventDestination -> Text
$sel:configurationSetName:UpdateEventDestination' :: UpdateEventDestination -> Text
$sel:snsDestination:UpdateEventDestination' :: UpdateEventDestination -> Maybe SnsDestination
$sel:matchingEventTypes:UpdateEventDestination' :: UpdateEventDestination -> Maybe (NonEmpty EventType)
$sel:kinesisFirehoseDestination:UpdateEventDestination' :: UpdateEventDestination -> Maybe KinesisFirehoseDestination
$sel:enabled:UpdateEventDestination' :: UpdateEventDestination -> Maybe Bool
$sel:cloudWatchLogsDestination:UpdateEventDestination' :: UpdateEventDestination -> Maybe CloudWatchLogsDestination
..} =
forall a. NFData a => a -> ()
Prelude.rnf Maybe CloudWatchLogsDestination
cloudWatchLogsDestination
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Bool
enabled
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe KinesisFirehoseDestination
kinesisFirehoseDestination
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe (NonEmpty EventType)
matchingEventTypes
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe SnsDestination
snsDestination
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
configurationSetName
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
eventDestinationName
instance Data.ToHeaders UpdateEventDestination where
toHeaders :: UpdateEventDestination -> ResponseHeaders
toHeaders =
forall a b. a -> b -> a
Prelude.const
( forall a. Monoid a => [a] -> a
Prelude.mconcat
[ HeaderName
"X-Amz-Target"
forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Data.=# ( ByteString
"PinpointSMSVoiceV2.UpdateEventDestination" ::
Prelude.ByteString
),
HeaderName
"Content-Type"
forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Data.=# ( ByteString
"application/x-amz-json-1.0" ::
Prelude.ByteString
)
]
)
instance Data.ToJSON UpdateEventDestination where
toJSON :: UpdateEventDestination -> Value
toJSON UpdateEventDestination' {Maybe Bool
Maybe (NonEmpty EventType)
Maybe CloudWatchLogsDestination
Maybe KinesisFirehoseDestination
Maybe SnsDestination
Text
eventDestinationName :: Text
configurationSetName :: Text
snsDestination :: Maybe SnsDestination
matchingEventTypes :: Maybe (NonEmpty EventType)
kinesisFirehoseDestination :: Maybe KinesisFirehoseDestination
enabled :: Maybe Bool
cloudWatchLogsDestination :: Maybe CloudWatchLogsDestination
$sel:eventDestinationName:UpdateEventDestination' :: UpdateEventDestination -> Text
$sel:configurationSetName:UpdateEventDestination' :: UpdateEventDestination -> Text
$sel:snsDestination:UpdateEventDestination' :: UpdateEventDestination -> Maybe SnsDestination
$sel:matchingEventTypes:UpdateEventDestination' :: UpdateEventDestination -> Maybe (NonEmpty EventType)
$sel:kinesisFirehoseDestination:UpdateEventDestination' :: UpdateEventDestination -> Maybe KinesisFirehoseDestination
$sel:enabled:UpdateEventDestination' :: UpdateEventDestination -> Maybe Bool
$sel:cloudWatchLogsDestination:UpdateEventDestination' :: UpdateEventDestination -> Maybe CloudWatchLogsDestination
..} =
[Pair] -> Value
Data.object
( forall a. [Maybe a] -> [a]
Prelude.catMaybes
[ (Key
"CloudWatchLogsDestination" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe CloudWatchLogsDestination
cloudWatchLogsDestination,
(Key
"Enabled" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Bool
enabled,
(Key
"KinesisFirehoseDestination" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe KinesisFirehoseDestination
kinesisFirehoseDestination,
(Key
"MatchingEventTypes" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (NonEmpty EventType)
matchingEventTypes,
(Key
"SnsDestination" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe SnsDestination
snsDestination,
forall a. a -> Maybe a
Prelude.Just
( Key
"ConfigurationSetName"
forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..= Text
configurationSetName
),
forall a. a -> Maybe a
Prelude.Just
( Key
"EventDestinationName"
forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..= Text
eventDestinationName
)
]
)
instance Data.ToPath UpdateEventDestination where
toPath :: UpdateEventDestination -> ByteString
toPath = forall a b. a -> b -> a
Prelude.const ByteString
"/"
instance Data.ToQuery UpdateEventDestination where
toQuery :: UpdateEventDestination -> QueryString
toQuery = forall a b. a -> b -> a
Prelude.const forall a. Monoid a => a
Prelude.mempty
data UpdateEventDestinationResponse = UpdateEventDestinationResponse'
{
UpdateEventDestinationResponse -> Maybe Text
configurationSetArn :: Prelude.Maybe Prelude.Text,
UpdateEventDestinationResponse -> Maybe Text
configurationSetName :: Prelude.Maybe Prelude.Text,
UpdateEventDestinationResponse -> Maybe EventDestination
eventDestination :: Prelude.Maybe EventDestination,
UpdateEventDestinationResponse -> Int
httpStatus :: Prelude.Int
}
deriving (UpdateEventDestinationResponse
-> UpdateEventDestinationResponse -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: UpdateEventDestinationResponse
-> UpdateEventDestinationResponse -> Bool
$c/= :: UpdateEventDestinationResponse
-> UpdateEventDestinationResponse -> Bool
== :: UpdateEventDestinationResponse
-> UpdateEventDestinationResponse -> Bool
$c== :: UpdateEventDestinationResponse
-> UpdateEventDestinationResponse -> Bool
Prelude.Eq, ReadPrec [UpdateEventDestinationResponse]
ReadPrec UpdateEventDestinationResponse
Int -> ReadS UpdateEventDestinationResponse
ReadS [UpdateEventDestinationResponse]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [UpdateEventDestinationResponse]
$creadListPrec :: ReadPrec [UpdateEventDestinationResponse]
readPrec :: ReadPrec UpdateEventDestinationResponse
$creadPrec :: ReadPrec UpdateEventDestinationResponse
readList :: ReadS [UpdateEventDestinationResponse]
$creadList :: ReadS [UpdateEventDestinationResponse]
readsPrec :: Int -> ReadS UpdateEventDestinationResponse
$creadsPrec :: Int -> ReadS UpdateEventDestinationResponse
Prelude.Read, Int -> UpdateEventDestinationResponse -> ShowS
[UpdateEventDestinationResponse] -> ShowS
UpdateEventDestinationResponse -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [UpdateEventDestinationResponse] -> ShowS
$cshowList :: [UpdateEventDestinationResponse] -> ShowS
show :: UpdateEventDestinationResponse -> String
$cshow :: UpdateEventDestinationResponse -> String
showsPrec :: Int -> UpdateEventDestinationResponse -> ShowS
$cshowsPrec :: Int -> UpdateEventDestinationResponse -> ShowS
Prelude.Show, forall x.
Rep UpdateEventDestinationResponse x
-> UpdateEventDestinationResponse
forall x.
UpdateEventDestinationResponse
-> Rep UpdateEventDestinationResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep UpdateEventDestinationResponse x
-> UpdateEventDestinationResponse
$cfrom :: forall x.
UpdateEventDestinationResponse
-> Rep UpdateEventDestinationResponse x
Prelude.Generic)
newUpdateEventDestinationResponse ::
Prelude.Int ->
UpdateEventDestinationResponse
newUpdateEventDestinationResponse :: Int -> UpdateEventDestinationResponse
newUpdateEventDestinationResponse Int
pHttpStatus_ =
UpdateEventDestinationResponse'
{ $sel:configurationSetArn:UpdateEventDestinationResponse' :: Maybe Text
configurationSetArn =
forall a. Maybe a
Prelude.Nothing,
$sel:configurationSetName:UpdateEventDestinationResponse' :: Maybe Text
configurationSetName = forall a. Maybe a
Prelude.Nothing,
$sel:eventDestination:UpdateEventDestinationResponse' :: Maybe EventDestination
eventDestination = forall a. Maybe a
Prelude.Nothing,
$sel:httpStatus:UpdateEventDestinationResponse' :: Int
httpStatus = Int
pHttpStatus_
}
updateEventDestinationResponse_configurationSetArn :: Lens.Lens' UpdateEventDestinationResponse (Prelude.Maybe Prelude.Text)
updateEventDestinationResponse_configurationSetArn :: Lens' UpdateEventDestinationResponse (Maybe Text)
updateEventDestinationResponse_configurationSetArn = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateEventDestinationResponse' {Maybe Text
configurationSetArn :: Maybe Text
$sel:configurationSetArn:UpdateEventDestinationResponse' :: UpdateEventDestinationResponse -> Maybe Text
configurationSetArn} -> Maybe Text
configurationSetArn) (\s :: UpdateEventDestinationResponse
s@UpdateEventDestinationResponse' {} Maybe Text
a -> UpdateEventDestinationResponse
s {$sel:configurationSetArn:UpdateEventDestinationResponse' :: Maybe Text
configurationSetArn = Maybe Text
a} :: UpdateEventDestinationResponse)
updateEventDestinationResponse_configurationSetName :: Lens.Lens' UpdateEventDestinationResponse (Prelude.Maybe Prelude.Text)
updateEventDestinationResponse_configurationSetName :: Lens' UpdateEventDestinationResponse (Maybe Text)
updateEventDestinationResponse_configurationSetName = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateEventDestinationResponse' {Maybe Text
configurationSetName :: Maybe Text
$sel:configurationSetName:UpdateEventDestinationResponse' :: UpdateEventDestinationResponse -> Maybe Text
configurationSetName} -> Maybe Text
configurationSetName) (\s :: UpdateEventDestinationResponse
s@UpdateEventDestinationResponse' {} Maybe Text
a -> UpdateEventDestinationResponse
s {$sel:configurationSetName:UpdateEventDestinationResponse' :: Maybe Text
configurationSetName = Maybe Text
a} :: UpdateEventDestinationResponse)
updateEventDestinationResponse_eventDestination :: Lens.Lens' UpdateEventDestinationResponse (Prelude.Maybe EventDestination)
updateEventDestinationResponse_eventDestination :: Lens' UpdateEventDestinationResponse (Maybe EventDestination)
updateEventDestinationResponse_eventDestination = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateEventDestinationResponse' {Maybe EventDestination
eventDestination :: Maybe EventDestination
$sel:eventDestination:UpdateEventDestinationResponse' :: UpdateEventDestinationResponse -> Maybe EventDestination
eventDestination} -> Maybe EventDestination
eventDestination) (\s :: UpdateEventDestinationResponse
s@UpdateEventDestinationResponse' {} Maybe EventDestination
a -> UpdateEventDestinationResponse
s {$sel:eventDestination:UpdateEventDestinationResponse' :: Maybe EventDestination
eventDestination = Maybe EventDestination
a} :: UpdateEventDestinationResponse)
updateEventDestinationResponse_httpStatus :: Lens.Lens' UpdateEventDestinationResponse Prelude.Int
updateEventDestinationResponse_httpStatus :: Lens' UpdateEventDestinationResponse Int
updateEventDestinationResponse_httpStatus = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateEventDestinationResponse' {Int
httpStatus :: Int
$sel:httpStatus:UpdateEventDestinationResponse' :: UpdateEventDestinationResponse -> Int
httpStatus} -> Int
httpStatus) (\s :: UpdateEventDestinationResponse
s@UpdateEventDestinationResponse' {} Int
a -> UpdateEventDestinationResponse
s {$sel:httpStatus:UpdateEventDestinationResponse' :: Int
httpStatus = Int
a} :: UpdateEventDestinationResponse)
instance
Prelude.NFData
UpdateEventDestinationResponse
where
rnf :: UpdateEventDestinationResponse -> ()
rnf UpdateEventDestinationResponse' {Int
Maybe Text
Maybe EventDestination
httpStatus :: Int
eventDestination :: Maybe EventDestination
configurationSetName :: Maybe Text
configurationSetArn :: Maybe Text
$sel:httpStatus:UpdateEventDestinationResponse' :: UpdateEventDestinationResponse -> Int
$sel:eventDestination:UpdateEventDestinationResponse' :: UpdateEventDestinationResponse -> Maybe EventDestination
$sel:configurationSetName:UpdateEventDestinationResponse' :: UpdateEventDestinationResponse -> Maybe Text
$sel:configurationSetArn:UpdateEventDestinationResponse' :: UpdateEventDestinationResponse -> Maybe Text
..} =
forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
configurationSetArn
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
configurationSetName
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe EventDestination
eventDestination
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Int
httpStatus