{-# 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.SageMaker.Types.WorkforceVpcConfigResponse 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 WorkforceVpcConfigResponse = WorkforceVpcConfigResponse'
{
WorkforceVpcConfigResponse -> Maybe Text
vpcEndpointId :: Prelude.Maybe Prelude.Text,
WorkforceVpcConfigResponse -> Text
vpcId :: Prelude.Text,
WorkforceVpcConfigResponse -> NonEmpty Text
securityGroupIds :: Prelude.NonEmpty Prelude.Text,
WorkforceVpcConfigResponse -> NonEmpty Text
subnets :: Prelude.NonEmpty Prelude.Text
}
deriving (WorkforceVpcConfigResponse -> WorkforceVpcConfigResponse -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: WorkforceVpcConfigResponse -> WorkforceVpcConfigResponse -> Bool
$c/= :: WorkforceVpcConfigResponse -> WorkforceVpcConfigResponse -> Bool
== :: WorkforceVpcConfigResponse -> WorkforceVpcConfigResponse -> Bool
$c== :: WorkforceVpcConfigResponse -> WorkforceVpcConfigResponse -> Bool
Prelude.Eq, ReadPrec [WorkforceVpcConfigResponse]
ReadPrec WorkforceVpcConfigResponse
Int -> ReadS WorkforceVpcConfigResponse
ReadS [WorkforceVpcConfigResponse]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [WorkforceVpcConfigResponse]
$creadListPrec :: ReadPrec [WorkforceVpcConfigResponse]
readPrec :: ReadPrec WorkforceVpcConfigResponse
$creadPrec :: ReadPrec WorkforceVpcConfigResponse
readList :: ReadS [WorkforceVpcConfigResponse]
$creadList :: ReadS [WorkforceVpcConfigResponse]
readsPrec :: Int -> ReadS WorkforceVpcConfigResponse
$creadsPrec :: Int -> ReadS WorkforceVpcConfigResponse
Prelude.Read, Int -> WorkforceVpcConfigResponse -> ShowS
[WorkforceVpcConfigResponse] -> ShowS
WorkforceVpcConfigResponse -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [WorkforceVpcConfigResponse] -> ShowS
$cshowList :: [WorkforceVpcConfigResponse] -> ShowS
show :: WorkforceVpcConfigResponse -> String
$cshow :: WorkforceVpcConfigResponse -> String
showsPrec :: Int -> WorkforceVpcConfigResponse -> ShowS
$cshowsPrec :: Int -> WorkforceVpcConfigResponse -> ShowS
Prelude.Show, forall x.
Rep WorkforceVpcConfigResponse x -> WorkforceVpcConfigResponse
forall x.
WorkforceVpcConfigResponse -> Rep WorkforceVpcConfigResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep WorkforceVpcConfigResponse x -> WorkforceVpcConfigResponse
$cfrom :: forall x.
WorkforceVpcConfigResponse -> Rep WorkforceVpcConfigResponse x
Prelude.Generic)
newWorkforceVpcConfigResponse ::
Prelude.Text ->
Prelude.NonEmpty Prelude.Text ->
Prelude.NonEmpty Prelude.Text ->
WorkforceVpcConfigResponse
newWorkforceVpcConfigResponse :: Text
-> NonEmpty Text -> NonEmpty Text -> WorkforceVpcConfigResponse
newWorkforceVpcConfigResponse
Text
pVpcId_
NonEmpty Text
pSecurityGroupIds_
NonEmpty Text
pSubnets_ =
WorkforceVpcConfigResponse'
{ $sel:vpcEndpointId:WorkforceVpcConfigResponse' :: Maybe Text
vpcEndpointId =
forall a. Maybe a
Prelude.Nothing,
$sel:vpcId:WorkforceVpcConfigResponse' :: Text
vpcId = Text
pVpcId_,
$sel:securityGroupIds:WorkforceVpcConfigResponse' :: NonEmpty Text
securityGroupIds =
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced forall t b. AReview t b -> b -> t
Lens.# NonEmpty Text
pSecurityGroupIds_,
$sel:subnets:WorkforceVpcConfigResponse' :: NonEmpty Text
subnets = forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced forall t b. AReview t b -> b -> t
Lens.# NonEmpty Text
pSubnets_
}
workforceVpcConfigResponse_vpcEndpointId :: Lens.Lens' WorkforceVpcConfigResponse (Prelude.Maybe Prelude.Text)
workforceVpcConfigResponse_vpcEndpointId :: Lens' WorkforceVpcConfigResponse (Maybe Text)
workforceVpcConfigResponse_vpcEndpointId = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\WorkforceVpcConfigResponse' {Maybe Text
vpcEndpointId :: Maybe Text
$sel:vpcEndpointId:WorkforceVpcConfigResponse' :: WorkforceVpcConfigResponse -> Maybe Text
vpcEndpointId} -> Maybe Text
vpcEndpointId) (\s :: WorkforceVpcConfigResponse
s@WorkforceVpcConfigResponse' {} Maybe Text
a -> WorkforceVpcConfigResponse
s {$sel:vpcEndpointId:WorkforceVpcConfigResponse' :: Maybe Text
vpcEndpointId = Maybe Text
a} :: WorkforceVpcConfigResponse)
workforceVpcConfigResponse_vpcId :: Lens.Lens' WorkforceVpcConfigResponse Prelude.Text
workforceVpcConfigResponse_vpcId :: Lens' WorkforceVpcConfigResponse Text
workforceVpcConfigResponse_vpcId = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\WorkforceVpcConfigResponse' {Text
vpcId :: Text
$sel:vpcId:WorkforceVpcConfigResponse' :: WorkforceVpcConfigResponse -> Text
vpcId} -> Text
vpcId) (\s :: WorkforceVpcConfigResponse
s@WorkforceVpcConfigResponse' {} Text
a -> WorkforceVpcConfigResponse
s {$sel:vpcId:WorkforceVpcConfigResponse' :: Text
vpcId = Text
a} :: WorkforceVpcConfigResponse)
workforceVpcConfigResponse_securityGroupIds :: Lens.Lens' WorkforceVpcConfigResponse (Prelude.NonEmpty Prelude.Text)
workforceVpcConfigResponse_securityGroupIds :: Lens' WorkforceVpcConfigResponse (NonEmpty Text)
workforceVpcConfigResponse_securityGroupIds = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\WorkforceVpcConfigResponse' {NonEmpty Text
securityGroupIds :: NonEmpty Text
$sel:securityGroupIds:WorkforceVpcConfigResponse' :: WorkforceVpcConfigResponse -> NonEmpty Text
securityGroupIds} -> NonEmpty Text
securityGroupIds) (\s :: WorkforceVpcConfigResponse
s@WorkforceVpcConfigResponse' {} NonEmpty Text
a -> WorkforceVpcConfigResponse
s {$sel:securityGroupIds:WorkforceVpcConfigResponse' :: NonEmpty Text
securityGroupIds = NonEmpty Text
a} :: WorkforceVpcConfigResponse) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
workforceVpcConfigResponse_subnets :: Lens.Lens' WorkforceVpcConfigResponse (Prelude.NonEmpty Prelude.Text)
workforceVpcConfigResponse_subnets :: Lens' WorkforceVpcConfigResponse (NonEmpty Text)
workforceVpcConfigResponse_subnets = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\WorkforceVpcConfigResponse' {NonEmpty Text
subnets :: NonEmpty Text
$sel:subnets:WorkforceVpcConfigResponse' :: WorkforceVpcConfigResponse -> NonEmpty Text
subnets} -> NonEmpty Text
subnets) (\s :: WorkforceVpcConfigResponse
s@WorkforceVpcConfigResponse' {} NonEmpty Text
a -> WorkforceVpcConfigResponse
s {$sel:subnets:WorkforceVpcConfigResponse' :: NonEmpty Text
subnets = NonEmpty Text
a} :: WorkforceVpcConfigResponse) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
instance Data.FromJSON WorkforceVpcConfigResponse where
parseJSON :: Value -> Parser WorkforceVpcConfigResponse
parseJSON =
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.withObject
String
"WorkforceVpcConfigResponse"
( \Object
x ->
Maybe Text
-> Text
-> NonEmpty Text
-> NonEmpty Text
-> WorkforceVpcConfigResponse
WorkforceVpcConfigResponse'
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
"VpcEndpointId")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser a
Data..: Key
"VpcId")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser a
Data..: Key
"SecurityGroupIds")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser a
Data..: Key
"Subnets")
)
instance Prelude.Hashable WorkforceVpcConfigResponse where
hashWithSalt :: Int -> WorkforceVpcConfigResponse -> Int
hashWithSalt Int
_salt WorkforceVpcConfigResponse' {Maybe Text
NonEmpty Text
Text
subnets :: NonEmpty Text
securityGroupIds :: NonEmpty Text
vpcId :: Text
vpcEndpointId :: Maybe Text
$sel:subnets:WorkforceVpcConfigResponse' :: WorkforceVpcConfigResponse -> NonEmpty Text
$sel:securityGroupIds:WorkforceVpcConfigResponse' :: WorkforceVpcConfigResponse -> NonEmpty Text
$sel:vpcId:WorkforceVpcConfigResponse' :: WorkforceVpcConfigResponse -> Text
$sel:vpcEndpointId:WorkforceVpcConfigResponse' :: WorkforceVpcConfigResponse -> Maybe Text
..} =
Int
_salt
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
vpcEndpointId
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
vpcId
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` NonEmpty Text
securityGroupIds
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` NonEmpty Text
subnets
instance Prelude.NFData WorkforceVpcConfigResponse where
rnf :: WorkforceVpcConfigResponse -> ()
rnf WorkforceVpcConfigResponse' {Maybe Text
NonEmpty Text
Text
subnets :: NonEmpty Text
securityGroupIds :: NonEmpty Text
vpcId :: Text
vpcEndpointId :: Maybe Text
$sel:subnets:WorkforceVpcConfigResponse' :: WorkforceVpcConfigResponse -> NonEmpty Text
$sel:securityGroupIds:WorkforceVpcConfigResponse' :: WorkforceVpcConfigResponse -> NonEmpty Text
$sel:vpcId:WorkforceVpcConfigResponse' :: WorkforceVpcConfigResponse -> Text
$sel:vpcEndpointId:WorkforceVpcConfigResponse' :: WorkforceVpcConfigResponse -> Maybe Text
..} =
forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
vpcEndpointId
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
vpcId
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf NonEmpty Text
securityGroupIds
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf NonEmpty Text
subnets