{-# 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.EC2.DisableVpcClassicLinkDnsSupport
(
DisableVpcClassicLinkDnsSupport (..),
newDisableVpcClassicLinkDnsSupport,
disableVpcClassicLinkDnsSupport_vpcId,
DisableVpcClassicLinkDnsSupportResponse (..),
newDisableVpcClassicLinkDnsSupportResponse,
disableVpcClassicLinkDnsSupportResponse_return,
disableVpcClassicLinkDnsSupportResponse_httpStatus,
)
where
import qualified Amazonka.Core as Core
import qualified Amazonka.Core.Lens.Internal as Lens
import qualified Amazonka.Data as Data
import Amazonka.EC2.Types
import qualified Amazonka.Prelude as Prelude
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response
data DisableVpcClassicLinkDnsSupport = DisableVpcClassicLinkDnsSupport'
{
DisableVpcClassicLinkDnsSupport -> Maybe Text
vpcId :: Prelude.Maybe Prelude.Text
}
deriving (DisableVpcClassicLinkDnsSupport
-> DisableVpcClassicLinkDnsSupport -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DisableVpcClassicLinkDnsSupport
-> DisableVpcClassicLinkDnsSupport -> Bool
$c/= :: DisableVpcClassicLinkDnsSupport
-> DisableVpcClassicLinkDnsSupport -> Bool
== :: DisableVpcClassicLinkDnsSupport
-> DisableVpcClassicLinkDnsSupport -> Bool
$c== :: DisableVpcClassicLinkDnsSupport
-> DisableVpcClassicLinkDnsSupport -> Bool
Prelude.Eq, ReadPrec [DisableVpcClassicLinkDnsSupport]
ReadPrec DisableVpcClassicLinkDnsSupport
Int -> ReadS DisableVpcClassicLinkDnsSupport
ReadS [DisableVpcClassicLinkDnsSupport]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DisableVpcClassicLinkDnsSupport]
$creadListPrec :: ReadPrec [DisableVpcClassicLinkDnsSupport]
readPrec :: ReadPrec DisableVpcClassicLinkDnsSupport
$creadPrec :: ReadPrec DisableVpcClassicLinkDnsSupport
readList :: ReadS [DisableVpcClassicLinkDnsSupport]
$creadList :: ReadS [DisableVpcClassicLinkDnsSupport]
readsPrec :: Int -> ReadS DisableVpcClassicLinkDnsSupport
$creadsPrec :: Int -> ReadS DisableVpcClassicLinkDnsSupport
Prelude.Read, Int -> DisableVpcClassicLinkDnsSupport -> ShowS
[DisableVpcClassicLinkDnsSupport] -> ShowS
DisableVpcClassicLinkDnsSupport -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DisableVpcClassicLinkDnsSupport] -> ShowS
$cshowList :: [DisableVpcClassicLinkDnsSupport] -> ShowS
show :: DisableVpcClassicLinkDnsSupport -> String
$cshow :: DisableVpcClassicLinkDnsSupport -> String
showsPrec :: Int -> DisableVpcClassicLinkDnsSupport -> ShowS
$cshowsPrec :: Int -> DisableVpcClassicLinkDnsSupport -> ShowS
Prelude.Show, forall x.
Rep DisableVpcClassicLinkDnsSupport x
-> DisableVpcClassicLinkDnsSupport
forall x.
DisableVpcClassicLinkDnsSupport
-> Rep DisableVpcClassicLinkDnsSupport x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep DisableVpcClassicLinkDnsSupport x
-> DisableVpcClassicLinkDnsSupport
$cfrom :: forall x.
DisableVpcClassicLinkDnsSupport
-> Rep DisableVpcClassicLinkDnsSupport x
Prelude.Generic)
newDisableVpcClassicLinkDnsSupport ::
DisableVpcClassicLinkDnsSupport
newDisableVpcClassicLinkDnsSupport :: DisableVpcClassicLinkDnsSupport
newDisableVpcClassicLinkDnsSupport =
DisableVpcClassicLinkDnsSupport'
{ $sel:vpcId:DisableVpcClassicLinkDnsSupport' :: Maybe Text
vpcId =
forall a. Maybe a
Prelude.Nothing
}
disableVpcClassicLinkDnsSupport_vpcId :: Lens.Lens' DisableVpcClassicLinkDnsSupport (Prelude.Maybe Prelude.Text)
disableVpcClassicLinkDnsSupport_vpcId :: Lens' DisableVpcClassicLinkDnsSupport (Maybe Text)
disableVpcClassicLinkDnsSupport_vpcId = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DisableVpcClassicLinkDnsSupport' {Maybe Text
vpcId :: Maybe Text
$sel:vpcId:DisableVpcClassicLinkDnsSupport' :: DisableVpcClassicLinkDnsSupport -> Maybe Text
vpcId} -> Maybe Text
vpcId) (\s :: DisableVpcClassicLinkDnsSupport
s@DisableVpcClassicLinkDnsSupport' {} Maybe Text
a -> DisableVpcClassicLinkDnsSupport
s {$sel:vpcId:DisableVpcClassicLinkDnsSupport' :: Maybe Text
vpcId = Maybe Text
a} :: DisableVpcClassicLinkDnsSupport)
instance
Core.AWSRequest
DisableVpcClassicLinkDnsSupport
where
type
AWSResponse DisableVpcClassicLinkDnsSupport =
DisableVpcClassicLinkDnsSupportResponse
request :: (Service -> Service)
-> DisableVpcClassicLinkDnsSupport
-> Request DisableVpcClassicLinkDnsSupport
request Service -> Service
overrides =
forall a. ToRequest a => Service -> a -> Request a
Request.postQuery (Service -> Service
overrides Service
defaultService)
response :: forall (m :: * -> *).
MonadResource m =>
(ByteStringLazy -> IO ByteStringLazy)
-> Service
-> Proxy DisableVpcClassicLinkDnsSupport
-> ClientResponse ClientBody
-> m (Either
Error
(ClientResponse (AWSResponse DisableVpcClassicLinkDnsSupport)))
response =
forall (m :: * -> *) a.
MonadResource m =>
(Int -> ResponseHeaders -> [Node] -> Either String (AWSResponse a))
-> (ByteStringLazy -> IO ByteStringLazy)
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveXML
( \Int
s ResponseHeaders
h [Node]
x ->
Maybe Bool -> Int -> DisableVpcClassicLinkDnsSupportResponse
DisableVpcClassicLinkDnsSupportResponse'
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> ([Node]
x forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Data..@? Text
"return")
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
DisableVpcClassicLinkDnsSupport
where
hashWithSalt :: Int -> DisableVpcClassicLinkDnsSupport -> Int
hashWithSalt
Int
_salt
DisableVpcClassicLinkDnsSupport' {Maybe Text
vpcId :: Maybe Text
$sel:vpcId:DisableVpcClassicLinkDnsSupport' :: DisableVpcClassicLinkDnsSupport -> Maybe Text
..} =
Int
_salt forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
vpcId
instance
Prelude.NFData
DisableVpcClassicLinkDnsSupport
where
rnf :: DisableVpcClassicLinkDnsSupport -> ()
rnf DisableVpcClassicLinkDnsSupport' {Maybe Text
vpcId :: Maybe Text
$sel:vpcId:DisableVpcClassicLinkDnsSupport' :: DisableVpcClassicLinkDnsSupport -> Maybe Text
..} =
forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
vpcId
instance
Data.ToHeaders
DisableVpcClassicLinkDnsSupport
where
toHeaders :: DisableVpcClassicLinkDnsSupport -> ResponseHeaders
toHeaders = forall a b. a -> b -> a
Prelude.const forall a. Monoid a => a
Prelude.mempty
instance Data.ToPath DisableVpcClassicLinkDnsSupport where
toPath :: DisableVpcClassicLinkDnsSupport -> ByteString
toPath = forall a b. a -> b -> a
Prelude.const ByteString
"/"
instance Data.ToQuery DisableVpcClassicLinkDnsSupport where
toQuery :: DisableVpcClassicLinkDnsSupport -> QueryString
toQuery DisableVpcClassicLinkDnsSupport' {Maybe Text
vpcId :: Maybe Text
$sel:vpcId:DisableVpcClassicLinkDnsSupport' :: DisableVpcClassicLinkDnsSupport -> Maybe Text
..} =
forall a. Monoid a => [a] -> a
Prelude.mconcat
[ ByteString
"Action"
forall a. ToQuery a => ByteString -> a -> QueryString
Data.=: ( ByteString
"DisableVpcClassicLinkDnsSupport" ::
Prelude.ByteString
),
ByteString
"Version"
forall a. ToQuery a => ByteString -> a -> QueryString
Data.=: (ByteString
"2016-11-15" :: Prelude.ByteString),
ByteString
"VpcId" forall a. ToQuery a => ByteString -> a -> QueryString
Data.=: Maybe Text
vpcId
]
data DisableVpcClassicLinkDnsSupportResponse = DisableVpcClassicLinkDnsSupportResponse'
{
DisableVpcClassicLinkDnsSupportResponse -> Maybe Bool
return' :: Prelude.Maybe Prelude.Bool,
DisableVpcClassicLinkDnsSupportResponse -> Int
httpStatus :: Prelude.Int
}
deriving (DisableVpcClassicLinkDnsSupportResponse
-> DisableVpcClassicLinkDnsSupportResponse -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DisableVpcClassicLinkDnsSupportResponse
-> DisableVpcClassicLinkDnsSupportResponse -> Bool
$c/= :: DisableVpcClassicLinkDnsSupportResponse
-> DisableVpcClassicLinkDnsSupportResponse -> Bool
== :: DisableVpcClassicLinkDnsSupportResponse
-> DisableVpcClassicLinkDnsSupportResponse -> Bool
$c== :: DisableVpcClassicLinkDnsSupportResponse
-> DisableVpcClassicLinkDnsSupportResponse -> Bool
Prelude.Eq, ReadPrec [DisableVpcClassicLinkDnsSupportResponse]
ReadPrec DisableVpcClassicLinkDnsSupportResponse
Int -> ReadS DisableVpcClassicLinkDnsSupportResponse
ReadS [DisableVpcClassicLinkDnsSupportResponse]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DisableVpcClassicLinkDnsSupportResponse]
$creadListPrec :: ReadPrec [DisableVpcClassicLinkDnsSupportResponse]
readPrec :: ReadPrec DisableVpcClassicLinkDnsSupportResponse
$creadPrec :: ReadPrec DisableVpcClassicLinkDnsSupportResponse
readList :: ReadS [DisableVpcClassicLinkDnsSupportResponse]
$creadList :: ReadS [DisableVpcClassicLinkDnsSupportResponse]
readsPrec :: Int -> ReadS DisableVpcClassicLinkDnsSupportResponse
$creadsPrec :: Int -> ReadS DisableVpcClassicLinkDnsSupportResponse
Prelude.Read, Int -> DisableVpcClassicLinkDnsSupportResponse -> ShowS
[DisableVpcClassicLinkDnsSupportResponse] -> ShowS
DisableVpcClassicLinkDnsSupportResponse -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DisableVpcClassicLinkDnsSupportResponse] -> ShowS
$cshowList :: [DisableVpcClassicLinkDnsSupportResponse] -> ShowS
show :: DisableVpcClassicLinkDnsSupportResponse -> String
$cshow :: DisableVpcClassicLinkDnsSupportResponse -> String
showsPrec :: Int -> DisableVpcClassicLinkDnsSupportResponse -> ShowS
$cshowsPrec :: Int -> DisableVpcClassicLinkDnsSupportResponse -> ShowS
Prelude.Show, forall x.
Rep DisableVpcClassicLinkDnsSupportResponse x
-> DisableVpcClassicLinkDnsSupportResponse
forall x.
DisableVpcClassicLinkDnsSupportResponse
-> Rep DisableVpcClassicLinkDnsSupportResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep DisableVpcClassicLinkDnsSupportResponse x
-> DisableVpcClassicLinkDnsSupportResponse
$cfrom :: forall x.
DisableVpcClassicLinkDnsSupportResponse
-> Rep DisableVpcClassicLinkDnsSupportResponse x
Prelude.Generic)
newDisableVpcClassicLinkDnsSupportResponse ::
Prelude.Int ->
DisableVpcClassicLinkDnsSupportResponse
newDisableVpcClassicLinkDnsSupportResponse :: Int -> DisableVpcClassicLinkDnsSupportResponse
newDisableVpcClassicLinkDnsSupportResponse
Int
pHttpStatus_ =
DisableVpcClassicLinkDnsSupportResponse'
{ $sel:return':DisableVpcClassicLinkDnsSupportResponse' :: Maybe Bool
return' =
forall a. Maybe a
Prelude.Nothing,
$sel:httpStatus:DisableVpcClassicLinkDnsSupportResponse' :: Int
httpStatus = Int
pHttpStatus_
}
disableVpcClassicLinkDnsSupportResponse_return :: Lens.Lens' DisableVpcClassicLinkDnsSupportResponse (Prelude.Maybe Prelude.Bool)
disableVpcClassicLinkDnsSupportResponse_return :: Lens' DisableVpcClassicLinkDnsSupportResponse (Maybe Bool)
disableVpcClassicLinkDnsSupportResponse_return = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DisableVpcClassicLinkDnsSupportResponse' {Maybe Bool
return' :: Maybe Bool
$sel:return':DisableVpcClassicLinkDnsSupportResponse' :: DisableVpcClassicLinkDnsSupportResponse -> Maybe Bool
return'} -> Maybe Bool
return') (\s :: DisableVpcClassicLinkDnsSupportResponse
s@DisableVpcClassicLinkDnsSupportResponse' {} Maybe Bool
a -> DisableVpcClassicLinkDnsSupportResponse
s {$sel:return':DisableVpcClassicLinkDnsSupportResponse' :: Maybe Bool
return' = Maybe Bool
a} :: DisableVpcClassicLinkDnsSupportResponse)
disableVpcClassicLinkDnsSupportResponse_httpStatus :: Lens.Lens' DisableVpcClassicLinkDnsSupportResponse Prelude.Int
disableVpcClassicLinkDnsSupportResponse_httpStatus :: Lens' DisableVpcClassicLinkDnsSupportResponse Int
disableVpcClassicLinkDnsSupportResponse_httpStatus = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DisableVpcClassicLinkDnsSupportResponse' {Int
httpStatus :: Int
$sel:httpStatus:DisableVpcClassicLinkDnsSupportResponse' :: DisableVpcClassicLinkDnsSupportResponse -> Int
httpStatus} -> Int
httpStatus) (\s :: DisableVpcClassicLinkDnsSupportResponse
s@DisableVpcClassicLinkDnsSupportResponse' {} Int
a -> DisableVpcClassicLinkDnsSupportResponse
s {$sel:httpStatus:DisableVpcClassicLinkDnsSupportResponse' :: Int
httpStatus = Int
a} :: DisableVpcClassicLinkDnsSupportResponse)
instance
Prelude.NFData
DisableVpcClassicLinkDnsSupportResponse
where
rnf :: DisableVpcClassicLinkDnsSupportResponse -> ()
rnf DisableVpcClassicLinkDnsSupportResponse' {Int
Maybe Bool
httpStatus :: Int
return' :: Maybe Bool
$sel:httpStatus:DisableVpcClassicLinkDnsSupportResponse' :: DisableVpcClassicLinkDnsSupportResponse -> Int
$sel:return':DisableVpcClassicLinkDnsSupportResponse' :: DisableVpcClassicLinkDnsSupportResponse -> Maybe Bool
..} =
forall a. NFData a => a -> ()
Prelude.rnf Maybe Bool
return'
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Int
httpStatus