{-# 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.SNS.SetPlatformApplicationAttributes
(
SetPlatformApplicationAttributes (..),
newSetPlatformApplicationAttributes,
setPlatformApplicationAttributes_platformApplicationArn,
setPlatformApplicationAttributes_attributes,
SetPlatformApplicationAttributesResponse (..),
newSetPlatformApplicationAttributesResponse,
)
where
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
import Amazonka.SNS.Types
data SetPlatformApplicationAttributes = SetPlatformApplicationAttributes'
{
SetPlatformApplicationAttributes -> Text
platformApplicationArn :: Prelude.Text,
SetPlatformApplicationAttributes -> HashMap Text Text
attributes :: Prelude.HashMap Prelude.Text Prelude.Text
}
deriving (SetPlatformApplicationAttributes
-> SetPlatformApplicationAttributes -> Bool
(SetPlatformApplicationAttributes
-> SetPlatformApplicationAttributes -> Bool)
-> (SetPlatformApplicationAttributes
-> SetPlatformApplicationAttributes -> Bool)
-> Eq SetPlatformApplicationAttributes
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: SetPlatformApplicationAttributes
-> SetPlatformApplicationAttributes -> Bool
$c/= :: SetPlatformApplicationAttributes
-> SetPlatformApplicationAttributes -> Bool
== :: SetPlatformApplicationAttributes
-> SetPlatformApplicationAttributes -> Bool
$c== :: SetPlatformApplicationAttributes
-> SetPlatformApplicationAttributes -> Bool
Prelude.Eq, ReadPrec [SetPlatformApplicationAttributes]
ReadPrec SetPlatformApplicationAttributes
Int -> ReadS SetPlatformApplicationAttributes
ReadS [SetPlatformApplicationAttributes]
(Int -> ReadS SetPlatformApplicationAttributes)
-> ReadS [SetPlatformApplicationAttributes]
-> ReadPrec SetPlatformApplicationAttributes
-> ReadPrec [SetPlatformApplicationAttributes]
-> Read SetPlatformApplicationAttributes
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [SetPlatformApplicationAttributes]
$creadListPrec :: ReadPrec [SetPlatformApplicationAttributes]
readPrec :: ReadPrec SetPlatformApplicationAttributes
$creadPrec :: ReadPrec SetPlatformApplicationAttributes
readList :: ReadS [SetPlatformApplicationAttributes]
$creadList :: ReadS [SetPlatformApplicationAttributes]
readsPrec :: Int -> ReadS SetPlatformApplicationAttributes
$creadsPrec :: Int -> ReadS SetPlatformApplicationAttributes
Prelude.Read, Int -> SetPlatformApplicationAttributes -> ShowS
[SetPlatformApplicationAttributes] -> ShowS
SetPlatformApplicationAttributes -> String
(Int -> SetPlatformApplicationAttributes -> ShowS)
-> (SetPlatformApplicationAttributes -> String)
-> ([SetPlatformApplicationAttributes] -> ShowS)
-> Show SetPlatformApplicationAttributes
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [SetPlatformApplicationAttributes] -> ShowS
$cshowList :: [SetPlatformApplicationAttributes] -> ShowS
show :: SetPlatformApplicationAttributes -> String
$cshow :: SetPlatformApplicationAttributes -> String
showsPrec :: Int -> SetPlatformApplicationAttributes -> ShowS
$cshowsPrec :: Int -> SetPlatformApplicationAttributes -> ShowS
Prelude.Show, (forall x.
SetPlatformApplicationAttributes
-> Rep SetPlatformApplicationAttributes x)
-> (forall x.
Rep SetPlatformApplicationAttributes x
-> SetPlatformApplicationAttributes)
-> Generic SetPlatformApplicationAttributes
forall x.
Rep SetPlatformApplicationAttributes x
-> SetPlatformApplicationAttributes
forall x.
SetPlatformApplicationAttributes
-> Rep SetPlatformApplicationAttributes x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep SetPlatformApplicationAttributes x
-> SetPlatformApplicationAttributes
$cfrom :: forall x.
SetPlatformApplicationAttributes
-> Rep SetPlatformApplicationAttributes x
Prelude.Generic)
newSetPlatformApplicationAttributes ::
Prelude.Text ->
SetPlatformApplicationAttributes
newSetPlatformApplicationAttributes :: Text -> SetPlatformApplicationAttributes
newSetPlatformApplicationAttributes
Text
pPlatformApplicationArn_ =
SetPlatformApplicationAttributes' :: Text -> HashMap Text Text -> SetPlatformApplicationAttributes
SetPlatformApplicationAttributes'
{ $sel:platformApplicationArn:SetPlatformApplicationAttributes' :: Text
platformApplicationArn =
Text
pPlatformApplicationArn_,
$sel:attributes:SetPlatformApplicationAttributes' :: HashMap Text Text
attributes = HashMap Text Text
forall a. Monoid a => a
Prelude.mempty
}
setPlatformApplicationAttributes_platformApplicationArn :: Lens.Lens' SetPlatformApplicationAttributes Prelude.Text
setPlatformApplicationAttributes_platformApplicationArn :: (Text -> f Text)
-> SetPlatformApplicationAttributes
-> f SetPlatformApplicationAttributes
setPlatformApplicationAttributes_platformApplicationArn = (SetPlatformApplicationAttributes -> Text)
-> (SetPlatformApplicationAttributes
-> Text -> SetPlatformApplicationAttributes)
-> Lens
SetPlatformApplicationAttributes
SetPlatformApplicationAttributes
Text
Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\SetPlatformApplicationAttributes' {Text
platformApplicationArn :: Text
$sel:platformApplicationArn:SetPlatformApplicationAttributes' :: SetPlatformApplicationAttributes -> Text
platformApplicationArn} -> Text
platformApplicationArn) (\s :: SetPlatformApplicationAttributes
s@SetPlatformApplicationAttributes' {} Text
a -> SetPlatformApplicationAttributes
s {$sel:platformApplicationArn:SetPlatformApplicationAttributes' :: Text
platformApplicationArn = Text
a} :: SetPlatformApplicationAttributes)
setPlatformApplicationAttributes_attributes :: Lens.Lens' SetPlatformApplicationAttributes (Prelude.HashMap Prelude.Text Prelude.Text)
setPlatformApplicationAttributes_attributes :: (HashMap Text Text -> f (HashMap Text Text))
-> SetPlatformApplicationAttributes
-> f SetPlatformApplicationAttributes
setPlatformApplicationAttributes_attributes = (SetPlatformApplicationAttributes -> HashMap Text Text)
-> (SetPlatformApplicationAttributes
-> HashMap Text Text -> SetPlatformApplicationAttributes)
-> Lens
SetPlatformApplicationAttributes
SetPlatformApplicationAttributes
(HashMap Text Text)
(HashMap Text Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\SetPlatformApplicationAttributes' {HashMap Text Text
attributes :: HashMap Text Text
$sel:attributes:SetPlatformApplicationAttributes' :: SetPlatformApplicationAttributes -> HashMap Text Text
attributes} -> HashMap Text Text
attributes) (\s :: SetPlatformApplicationAttributes
s@SetPlatformApplicationAttributes' {} HashMap Text Text
a -> SetPlatformApplicationAttributes
s {$sel:attributes:SetPlatformApplicationAttributes' :: HashMap Text Text
attributes = HashMap Text Text
a} :: SetPlatformApplicationAttributes) ((HashMap Text Text -> f (HashMap Text Text))
-> SetPlatformApplicationAttributes
-> f SetPlatformApplicationAttributes)
-> ((HashMap Text Text -> f (HashMap Text Text))
-> HashMap Text Text -> f (HashMap Text Text))
-> (HashMap Text Text -> f (HashMap Text Text))
-> SetPlatformApplicationAttributes
-> f SetPlatformApplicationAttributes
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. (HashMap Text Text -> f (HashMap Text Text))
-> HashMap Text Text -> f (HashMap Text Text)
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
instance
Core.AWSRequest
SetPlatformApplicationAttributes
where
type
AWSResponse SetPlatformApplicationAttributes =
SetPlatformApplicationAttributesResponse
request :: SetPlatformApplicationAttributes
-> Request SetPlatformApplicationAttributes
request = Service
-> SetPlatformApplicationAttributes
-> Request SetPlatformApplicationAttributes
forall a. ToRequest a => Service -> a -> Request a
Request.postQuery Service
defaultService
response :: Logger
-> Service
-> Proxy SetPlatformApplicationAttributes
-> ClientResponse ClientBody
-> m (Either
Error
(ClientResponse (AWSResponse SetPlatformApplicationAttributes)))
response =
AWSResponse SetPlatformApplicationAttributes
-> Logger
-> Service
-> Proxy SetPlatformApplicationAttributes
-> ClientResponse ClientBody
-> m (Either
Error
(ClientResponse (AWSResponse SetPlatformApplicationAttributes)))
forall (m :: * -> *) a.
MonadResource m =>
AWSResponse a
-> Logger
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveNull
AWSResponse SetPlatformApplicationAttributes
SetPlatformApplicationAttributesResponse
SetPlatformApplicationAttributesResponse'
instance
Prelude.Hashable
SetPlatformApplicationAttributes
instance
Prelude.NFData
SetPlatformApplicationAttributes
instance
Core.ToHeaders
SetPlatformApplicationAttributes
where
toHeaders :: SetPlatformApplicationAttributes -> [Header]
toHeaders = [Header] -> SetPlatformApplicationAttributes -> [Header]
forall a b. a -> b -> a
Prelude.const [Header]
forall a. Monoid a => a
Prelude.mempty
instance Core.ToPath SetPlatformApplicationAttributes where
toPath :: SetPlatformApplicationAttributes -> ByteString
toPath = ByteString -> SetPlatformApplicationAttributes -> ByteString
forall a b. a -> b -> a
Prelude.const ByteString
"/"
instance
Core.ToQuery
SetPlatformApplicationAttributes
where
toQuery :: SetPlatformApplicationAttributes -> QueryString
toQuery SetPlatformApplicationAttributes' {Text
HashMap Text Text
attributes :: HashMap Text Text
platformApplicationArn :: Text
$sel:attributes:SetPlatformApplicationAttributes' :: SetPlatformApplicationAttributes -> HashMap Text Text
$sel:platformApplicationArn:SetPlatformApplicationAttributes' :: SetPlatformApplicationAttributes -> 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
"SetPlatformApplicationAttributes" ::
Prelude.ByteString
),
ByteString
"Version"
ByteString -> ByteString -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: (ByteString
"2010-03-31" :: Prelude.ByteString),
ByteString
"PlatformApplicationArn"
ByteString -> Text -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: Text
platformApplicationArn,
ByteString
"Attributes"
ByteString -> QueryString -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: ByteString
-> ByteString -> ByteString -> HashMap Text Text -> QueryString
forall k v.
(ToQuery k, ToQuery v) =>
ByteString
-> ByteString -> ByteString -> HashMap k v -> QueryString
Core.toQueryMap ByteString
"entry" ByteString
"key" ByteString
"value" HashMap Text Text
attributes
]
data SetPlatformApplicationAttributesResponse = SetPlatformApplicationAttributesResponse'
{
}
deriving (SetPlatformApplicationAttributesResponse
-> SetPlatformApplicationAttributesResponse -> Bool
(SetPlatformApplicationAttributesResponse
-> SetPlatformApplicationAttributesResponse -> Bool)
-> (SetPlatformApplicationAttributesResponse
-> SetPlatformApplicationAttributesResponse -> Bool)
-> Eq SetPlatformApplicationAttributesResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: SetPlatformApplicationAttributesResponse
-> SetPlatformApplicationAttributesResponse -> Bool
$c/= :: SetPlatformApplicationAttributesResponse
-> SetPlatformApplicationAttributesResponse -> Bool
== :: SetPlatformApplicationAttributesResponse
-> SetPlatformApplicationAttributesResponse -> Bool
$c== :: SetPlatformApplicationAttributesResponse
-> SetPlatformApplicationAttributesResponse -> Bool
Prelude.Eq, ReadPrec [SetPlatformApplicationAttributesResponse]
ReadPrec SetPlatformApplicationAttributesResponse
Int -> ReadS SetPlatformApplicationAttributesResponse
ReadS [SetPlatformApplicationAttributesResponse]
(Int -> ReadS SetPlatformApplicationAttributesResponse)
-> ReadS [SetPlatformApplicationAttributesResponse]
-> ReadPrec SetPlatformApplicationAttributesResponse
-> ReadPrec [SetPlatformApplicationAttributesResponse]
-> Read SetPlatformApplicationAttributesResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [SetPlatformApplicationAttributesResponse]
$creadListPrec :: ReadPrec [SetPlatformApplicationAttributesResponse]
readPrec :: ReadPrec SetPlatformApplicationAttributesResponse
$creadPrec :: ReadPrec SetPlatformApplicationAttributesResponse
readList :: ReadS [SetPlatformApplicationAttributesResponse]
$creadList :: ReadS [SetPlatformApplicationAttributesResponse]
readsPrec :: Int -> ReadS SetPlatformApplicationAttributesResponse
$creadsPrec :: Int -> ReadS SetPlatformApplicationAttributesResponse
Prelude.Read, Int -> SetPlatformApplicationAttributesResponse -> ShowS
[SetPlatformApplicationAttributesResponse] -> ShowS
SetPlatformApplicationAttributesResponse -> String
(Int -> SetPlatformApplicationAttributesResponse -> ShowS)
-> (SetPlatformApplicationAttributesResponse -> String)
-> ([SetPlatformApplicationAttributesResponse] -> ShowS)
-> Show SetPlatformApplicationAttributesResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [SetPlatformApplicationAttributesResponse] -> ShowS
$cshowList :: [SetPlatformApplicationAttributesResponse] -> ShowS
show :: SetPlatformApplicationAttributesResponse -> String
$cshow :: SetPlatformApplicationAttributesResponse -> String
showsPrec :: Int -> SetPlatformApplicationAttributesResponse -> ShowS
$cshowsPrec :: Int -> SetPlatformApplicationAttributesResponse -> ShowS
Prelude.Show, (forall x.
SetPlatformApplicationAttributesResponse
-> Rep SetPlatformApplicationAttributesResponse x)
-> (forall x.
Rep SetPlatformApplicationAttributesResponse x
-> SetPlatformApplicationAttributesResponse)
-> Generic SetPlatformApplicationAttributesResponse
forall x.
Rep SetPlatformApplicationAttributesResponse x
-> SetPlatformApplicationAttributesResponse
forall x.
SetPlatformApplicationAttributesResponse
-> Rep SetPlatformApplicationAttributesResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep SetPlatformApplicationAttributesResponse x
-> SetPlatformApplicationAttributesResponse
$cfrom :: forall x.
SetPlatformApplicationAttributesResponse
-> Rep SetPlatformApplicationAttributesResponse x
Prelude.Generic)
newSetPlatformApplicationAttributesResponse ::
SetPlatformApplicationAttributesResponse
newSetPlatformApplicationAttributesResponse :: SetPlatformApplicationAttributesResponse
newSetPlatformApplicationAttributesResponse =
SetPlatformApplicationAttributesResponse
SetPlatformApplicationAttributesResponse'
instance
Prelude.NFData
SetPlatformApplicationAttributesResponse