{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE DuplicateRecordFields #-}
{-# LANGUAGE NamedFieldPuns #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}
module Amazonka.GameLift.Types.VpcPeeringConnectionStatus where
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
data VpcPeeringConnectionStatus = VpcPeeringConnectionStatus'
{
VpcPeeringConnectionStatus -> Maybe Text
code :: Prelude.Maybe Prelude.Text,
VpcPeeringConnectionStatus -> Maybe Text
message :: Prelude.Maybe Prelude.Text
}
deriving (VpcPeeringConnectionStatus -> VpcPeeringConnectionStatus -> Bool
(VpcPeeringConnectionStatus -> VpcPeeringConnectionStatus -> Bool)
-> (VpcPeeringConnectionStatus
-> VpcPeeringConnectionStatus -> Bool)
-> Eq VpcPeeringConnectionStatus
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: VpcPeeringConnectionStatus -> VpcPeeringConnectionStatus -> Bool
$c/= :: VpcPeeringConnectionStatus -> VpcPeeringConnectionStatus -> Bool
== :: VpcPeeringConnectionStatus -> VpcPeeringConnectionStatus -> Bool
$c== :: VpcPeeringConnectionStatus -> VpcPeeringConnectionStatus -> Bool
Prelude.Eq, ReadPrec [VpcPeeringConnectionStatus]
ReadPrec VpcPeeringConnectionStatus
Int -> ReadS VpcPeeringConnectionStatus
ReadS [VpcPeeringConnectionStatus]
(Int -> ReadS VpcPeeringConnectionStatus)
-> ReadS [VpcPeeringConnectionStatus]
-> ReadPrec VpcPeeringConnectionStatus
-> ReadPrec [VpcPeeringConnectionStatus]
-> Read VpcPeeringConnectionStatus
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [VpcPeeringConnectionStatus]
$creadListPrec :: ReadPrec [VpcPeeringConnectionStatus]
readPrec :: ReadPrec VpcPeeringConnectionStatus
$creadPrec :: ReadPrec VpcPeeringConnectionStatus
readList :: ReadS [VpcPeeringConnectionStatus]
$creadList :: ReadS [VpcPeeringConnectionStatus]
readsPrec :: Int -> ReadS VpcPeeringConnectionStatus
$creadsPrec :: Int -> ReadS VpcPeeringConnectionStatus
Prelude.Read, Int -> VpcPeeringConnectionStatus -> ShowS
[VpcPeeringConnectionStatus] -> ShowS
VpcPeeringConnectionStatus -> String
(Int -> VpcPeeringConnectionStatus -> ShowS)
-> (VpcPeeringConnectionStatus -> String)
-> ([VpcPeeringConnectionStatus] -> ShowS)
-> Show VpcPeeringConnectionStatus
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [VpcPeeringConnectionStatus] -> ShowS
$cshowList :: [VpcPeeringConnectionStatus] -> ShowS
show :: VpcPeeringConnectionStatus -> String
$cshow :: VpcPeeringConnectionStatus -> String
showsPrec :: Int -> VpcPeeringConnectionStatus -> ShowS
$cshowsPrec :: Int -> VpcPeeringConnectionStatus -> ShowS
Prelude.Show, (forall x.
VpcPeeringConnectionStatus -> Rep VpcPeeringConnectionStatus x)
-> (forall x.
Rep VpcPeeringConnectionStatus x -> VpcPeeringConnectionStatus)
-> Generic VpcPeeringConnectionStatus
forall x.
Rep VpcPeeringConnectionStatus x -> VpcPeeringConnectionStatus
forall x.
VpcPeeringConnectionStatus -> Rep VpcPeeringConnectionStatus x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep VpcPeeringConnectionStatus x -> VpcPeeringConnectionStatus
$cfrom :: forall x.
VpcPeeringConnectionStatus -> Rep VpcPeeringConnectionStatus x
Prelude.Generic)
newVpcPeeringConnectionStatus ::
VpcPeeringConnectionStatus
newVpcPeeringConnectionStatus :: VpcPeeringConnectionStatus
newVpcPeeringConnectionStatus =
VpcPeeringConnectionStatus' :: Maybe Text -> Maybe Text -> VpcPeeringConnectionStatus
VpcPeeringConnectionStatus'
{ $sel:code:VpcPeeringConnectionStatus' :: Maybe Text
code = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:message:VpcPeeringConnectionStatus' :: Maybe Text
message = Maybe Text
forall a. Maybe a
Prelude.Nothing
}
vpcPeeringConnectionStatus_code :: Lens.Lens' VpcPeeringConnectionStatus (Prelude.Maybe Prelude.Text)
vpcPeeringConnectionStatus_code :: (Maybe Text -> f (Maybe Text))
-> VpcPeeringConnectionStatus -> f VpcPeeringConnectionStatus
vpcPeeringConnectionStatus_code = (VpcPeeringConnectionStatus -> Maybe Text)
-> (VpcPeeringConnectionStatus
-> Maybe Text -> VpcPeeringConnectionStatus)
-> Lens
VpcPeeringConnectionStatus
VpcPeeringConnectionStatus
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\VpcPeeringConnectionStatus' {Maybe Text
code :: Maybe Text
$sel:code:VpcPeeringConnectionStatus' :: VpcPeeringConnectionStatus -> Maybe Text
code} -> Maybe Text
code) (\s :: VpcPeeringConnectionStatus
s@VpcPeeringConnectionStatus' {} Maybe Text
a -> VpcPeeringConnectionStatus
s {$sel:code:VpcPeeringConnectionStatus' :: Maybe Text
code = Maybe Text
a} :: VpcPeeringConnectionStatus)
vpcPeeringConnectionStatus_message :: Lens.Lens' VpcPeeringConnectionStatus (Prelude.Maybe Prelude.Text)
vpcPeeringConnectionStatus_message :: (Maybe Text -> f (Maybe Text))
-> VpcPeeringConnectionStatus -> f VpcPeeringConnectionStatus
vpcPeeringConnectionStatus_message = (VpcPeeringConnectionStatus -> Maybe Text)
-> (VpcPeeringConnectionStatus
-> Maybe Text -> VpcPeeringConnectionStatus)
-> Lens
VpcPeeringConnectionStatus
VpcPeeringConnectionStatus
(Maybe Text)
(Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\VpcPeeringConnectionStatus' {Maybe Text
message :: Maybe Text
$sel:message:VpcPeeringConnectionStatus' :: VpcPeeringConnectionStatus -> Maybe Text
message} -> Maybe Text
message) (\s :: VpcPeeringConnectionStatus
s@VpcPeeringConnectionStatus' {} Maybe Text
a -> VpcPeeringConnectionStatus
s {$sel:message:VpcPeeringConnectionStatus' :: Maybe Text
message = Maybe Text
a} :: VpcPeeringConnectionStatus)
instance Core.FromJSON VpcPeeringConnectionStatus where
parseJSON :: Value -> Parser VpcPeeringConnectionStatus
parseJSON =
String
-> (Object -> Parser VpcPeeringConnectionStatus)
-> Value
-> Parser VpcPeeringConnectionStatus
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
String
"VpcPeeringConnectionStatus"
( \Object
x ->
Maybe Text -> Maybe Text -> VpcPeeringConnectionStatus
VpcPeeringConnectionStatus'
(Maybe Text -> Maybe Text -> VpcPeeringConnectionStatus)
-> Parser (Maybe Text)
-> Parser (Maybe Text -> VpcPeeringConnectionStatus)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Code")
Parser (Maybe Text -> VpcPeeringConnectionStatus)
-> Parser (Maybe Text) -> Parser VpcPeeringConnectionStatus
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Message")
)
instance Prelude.Hashable VpcPeeringConnectionStatus
instance Prelude.NFData VpcPeeringConnectionStatus