{-# 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.MediaLive.Types.InputDestinationVpc where
import qualified Amazonka.Core as Core
import qualified Amazonka.Core.Lens.Internal as Lens
import qualified Amazonka.Data as Data
import qualified Amazonka.Prelude as Prelude
data InputDestinationVpc = InputDestinationVpc'
{
InputDestinationVpc -> Maybe Text
availabilityZone :: Prelude.Maybe Prelude.Text,
InputDestinationVpc -> Maybe Text
networkInterfaceId :: Prelude.Maybe Prelude.Text
}
deriving (InputDestinationVpc -> InputDestinationVpc -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: InputDestinationVpc -> InputDestinationVpc -> Bool
$c/= :: InputDestinationVpc -> InputDestinationVpc -> Bool
== :: InputDestinationVpc -> InputDestinationVpc -> Bool
$c== :: InputDestinationVpc -> InputDestinationVpc -> Bool
Prelude.Eq, ReadPrec [InputDestinationVpc]
ReadPrec InputDestinationVpc
Int -> ReadS InputDestinationVpc
ReadS [InputDestinationVpc]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [InputDestinationVpc]
$creadListPrec :: ReadPrec [InputDestinationVpc]
readPrec :: ReadPrec InputDestinationVpc
$creadPrec :: ReadPrec InputDestinationVpc
readList :: ReadS [InputDestinationVpc]
$creadList :: ReadS [InputDestinationVpc]
readsPrec :: Int -> ReadS InputDestinationVpc
$creadsPrec :: Int -> ReadS InputDestinationVpc
Prelude.Read, Int -> InputDestinationVpc -> ShowS
[InputDestinationVpc] -> ShowS
InputDestinationVpc -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [InputDestinationVpc] -> ShowS
$cshowList :: [InputDestinationVpc] -> ShowS
show :: InputDestinationVpc -> String
$cshow :: InputDestinationVpc -> String
showsPrec :: Int -> InputDestinationVpc -> ShowS
$cshowsPrec :: Int -> InputDestinationVpc -> ShowS
Prelude.Show, forall x. Rep InputDestinationVpc x -> InputDestinationVpc
forall x. InputDestinationVpc -> Rep InputDestinationVpc x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep InputDestinationVpc x -> InputDestinationVpc
$cfrom :: forall x. InputDestinationVpc -> Rep InputDestinationVpc x
Prelude.Generic)
newInputDestinationVpc ::
InputDestinationVpc
newInputDestinationVpc :: InputDestinationVpc
newInputDestinationVpc =
InputDestinationVpc'
{ $sel:availabilityZone:InputDestinationVpc' :: Maybe Text
availabilityZone =
forall a. Maybe a
Prelude.Nothing,
$sel:networkInterfaceId:InputDestinationVpc' :: Maybe Text
networkInterfaceId = forall a. Maybe a
Prelude.Nothing
}
inputDestinationVpc_availabilityZone :: Lens.Lens' InputDestinationVpc (Prelude.Maybe Prelude.Text)
inputDestinationVpc_availabilityZone :: Lens' InputDestinationVpc (Maybe Text)
inputDestinationVpc_availabilityZone = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InputDestinationVpc' {Maybe Text
availabilityZone :: Maybe Text
$sel:availabilityZone:InputDestinationVpc' :: InputDestinationVpc -> Maybe Text
availabilityZone} -> Maybe Text
availabilityZone) (\s :: InputDestinationVpc
s@InputDestinationVpc' {} Maybe Text
a -> InputDestinationVpc
s {$sel:availabilityZone:InputDestinationVpc' :: Maybe Text
availabilityZone = Maybe Text
a} :: InputDestinationVpc)
inputDestinationVpc_networkInterfaceId :: Lens.Lens' InputDestinationVpc (Prelude.Maybe Prelude.Text)
inputDestinationVpc_networkInterfaceId :: Lens' InputDestinationVpc (Maybe Text)
inputDestinationVpc_networkInterfaceId = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InputDestinationVpc' {Maybe Text
networkInterfaceId :: Maybe Text
$sel:networkInterfaceId:InputDestinationVpc' :: InputDestinationVpc -> Maybe Text
networkInterfaceId} -> Maybe Text
networkInterfaceId) (\s :: InputDestinationVpc
s@InputDestinationVpc' {} Maybe Text
a -> InputDestinationVpc
s {$sel:networkInterfaceId:InputDestinationVpc' :: Maybe Text
networkInterfaceId = Maybe Text
a} :: InputDestinationVpc)
instance Data.FromJSON InputDestinationVpc where
parseJSON :: Value -> Parser InputDestinationVpc
parseJSON =
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.withObject
String
"InputDestinationVpc"
( \Object
x ->
Maybe Text -> Maybe Text -> InputDestinationVpc
InputDestinationVpc'
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"availabilityZone")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"networkInterfaceId")
)
instance Prelude.Hashable InputDestinationVpc where
hashWithSalt :: Int -> InputDestinationVpc -> Int
hashWithSalt Int
_salt InputDestinationVpc' {Maybe Text
networkInterfaceId :: Maybe Text
availabilityZone :: Maybe Text
$sel:networkInterfaceId:InputDestinationVpc' :: InputDestinationVpc -> Maybe Text
$sel:availabilityZone:InputDestinationVpc' :: InputDestinationVpc -> Maybe Text
..} =
Int
_salt
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
availabilityZone
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
networkInterfaceId
instance Prelude.NFData InputDestinationVpc where
rnf :: InputDestinationVpc -> ()
rnf InputDestinationVpc' {Maybe Text
networkInterfaceId :: Maybe Text
availabilityZone :: Maybe Text
$sel:networkInterfaceId:InputDestinationVpc' :: InputDestinationVpc -> Maybe Text
$sel:availabilityZone:InputDestinationVpc' :: InputDestinationVpc -> Maybe Text
..} =
forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
availabilityZone
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
networkInterfaceId