module Stratosphere.Redshift.EndpointAccess (
        EndpointAccess(..), mkEndpointAccess
    ) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import Stratosphere.ResourceProperties
import Stratosphere.Value
data EndpointAccess
  = -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-redshift-endpointaccess.html>
    EndpointAccess {EndpointAccess -> ()
haddock_workaround_ :: (),
                    -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-redshift-endpointaccess.html#cfn-redshift-endpointaccess-clusteridentifier>
                    EndpointAccess -> Value Text
clusterIdentifier :: (Value Prelude.Text),
                    -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-redshift-endpointaccess.html#cfn-redshift-endpointaccess-endpointname>
                    EndpointAccess -> Value Text
endpointName :: (Value Prelude.Text),
                    -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-redshift-endpointaccess.html#cfn-redshift-endpointaccess-resourceowner>
                    EndpointAccess -> Maybe (Value Text)
resourceOwner :: (Prelude.Maybe (Value Prelude.Text)),
                    -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-redshift-endpointaccess.html#cfn-redshift-endpointaccess-subnetgroupname>
                    EndpointAccess -> Value Text
subnetGroupName :: (Value Prelude.Text),
                    -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-redshift-endpointaccess.html#cfn-redshift-endpointaccess-vpcsecuritygroupids>
                    EndpointAccess -> ValueList Text
vpcSecurityGroupIds :: (ValueList Prelude.Text)}
  deriving stock (EndpointAccess -> EndpointAccess -> Bool
(EndpointAccess -> EndpointAccess -> Bool)
-> (EndpointAccess -> EndpointAccess -> Bool) -> Eq EndpointAccess
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: EndpointAccess -> EndpointAccess -> Bool
== :: EndpointAccess -> EndpointAccess -> Bool
$c/= :: EndpointAccess -> EndpointAccess -> Bool
/= :: EndpointAccess -> EndpointAccess -> Bool
Prelude.Eq, Int -> EndpointAccess -> ShowS
[EndpointAccess] -> ShowS
EndpointAccess -> String
(Int -> EndpointAccess -> ShowS)
-> (EndpointAccess -> String)
-> ([EndpointAccess] -> ShowS)
-> Show EndpointAccess
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> EndpointAccess -> ShowS
showsPrec :: Int -> EndpointAccess -> ShowS
$cshow :: EndpointAccess -> String
show :: EndpointAccess -> String
$cshowList :: [EndpointAccess] -> ShowS
showList :: [EndpointAccess] -> ShowS
Prelude.Show)
mkEndpointAccess ::
  Value Prelude.Text
  -> Value Prelude.Text
     -> Value Prelude.Text -> ValueList Prelude.Text -> EndpointAccess
mkEndpointAccess :: Value Text
-> Value Text -> Value Text -> ValueList Text -> EndpointAccess
mkEndpointAccess
  Value Text
clusterIdentifier
  Value Text
endpointName
  Value Text
subnetGroupName
  ValueList Text
vpcSecurityGroupIds
  = EndpointAccess
      {haddock_workaround_ :: ()
haddock_workaround_ = (), clusterIdentifier :: Value Text
clusterIdentifier = Value Text
clusterIdentifier,
       endpointName :: Value Text
endpointName = Value Text
endpointName, subnetGroupName :: Value Text
subnetGroupName = Value Text
subnetGroupName,
       vpcSecurityGroupIds :: ValueList Text
vpcSecurityGroupIds = ValueList Text
vpcSecurityGroupIds,
       resourceOwner :: Maybe (Value Text)
resourceOwner = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties EndpointAccess where
  toResourceProperties :: EndpointAccess -> ResourceProperties
toResourceProperties EndpointAccess {Maybe (Value Text)
()
ValueList Text
Value Text
haddock_workaround_ :: EndpointAccess -> ()
clusterIdentifier :: EndpointAccess -> Value Text
endpointName :: EndpointAccess -> Value Text
resourceOwner :: EndpointAccess -> Maybe (Value Text)
subnetGroupName :: EndpointAccess -> Value Text
vpcSecurityGroupIds :: EndpointAccess -> ValueList Text
haddock_workaround_ :: ()
clusterIdentifier :: Value Text
endpointName :: Value Text
resourceOwner :: Maybe (Value Text)
subnetGroupName :: Value Text
vpcSecurityGroupIds :: ValueList Text
..}
    = ResourceProperties
        {awsType :: Text
awsType = Text
"AWS::Redshift::EndpointAccess",
         supportsTags :: Bool
supportsTags = Bool
Prelude.False,
         properties :: Object
properties = [Item Object] -> Object
forall l. IsList l => [Item l] -> l
Prelude.fromList
                        ([(Key, Value)] -> [(Key, Value)] -> [(Key, Value)]
forall a. Semigroup a => a -> a -> a
(Prelude.<>)
                           [Key
"ClusterIdentifier" Key -> Value Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= Value Text
clusterIdentifier,
                            Key
"EndpointName" Key -> Value Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= Value Text
endpointName,
                            Key
"SubnetGroupName" Key -> Value Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= Value Text
subnetGroupName,
                            Key
"VpcSecurityGroupIds" Key -> ValueList Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= ValueList Text
vpcSecurityGroupIds]
                           ([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
                              [Key -> Value Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"ResourceOwner" (Value Text -> (Key, Value))
-> Maybe (Value Text) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Text)
resourceOwner]))}
instance JSON.ToJSON EndpointAccess where
  toJSON :: EndpointAccess -> Value
toJSON EndpointAccess {Maybe (Value Text)
()
ValueList Text
Value Text
haddock_workaround_ :: EndpointAccess -> ()
clusterIdentifier :: EndpointAccess -> Value Text
endpointName :: EndpointAccess -> Value Text
resourceOwner :: EndpointAccess -> Maybe (Value Text)
subnetGroupName :: EndpointAccess -> Value Text
vpcSecurityGroupIds :: EndpointAccess -> ValueList Text
haddock_workaround_ :: ()
clusterIdentifier :: Value Text
endpointName :: Value Text
resourceOwner :: Maybe (Value Text)
subnetGroupName :: Value Text
vpcSecurityGroupIds :: ValueList Text
..}
    = [(Key, Value)] -> Value
JSON.object
        ([Item [(Key, Value)]] -> [(Key, Value)]
forall l. IsList l => [Item l] -> l
Prelude.fromList
           ([(Key, Value)] -> [(Key, Value)] -> [(Key, Value)]
forall a. Semigroup a => a -> a -> a
(Prelude.<>)
              [Key
"ClusterIdentifier" Key -> Value Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= Value Text
clusterIdentifier,
               Key
"EndpointName" Key -> Value Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= Value Text
endpointName,
               Key
"SubnetGroupName" Key -> Value Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= Value Text
subnetGroupName,
               Key
"VpcSecurityGroupIds" Key -> ValueList Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= ValueList Text
vpcSecurityGroupIds]
              ([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
                 [Key -> Value Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"ResourceOwner" (Value Text -> (Key, Value))
-> Maybe (Value Text) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Text)
resourceOwner])))
instance Property "ClusterIdentifier" EndpointAccess where
  type PropertyType "ClusterIdentifier" EndpointAccess = Value Prelude.Text
  set :: PropertyType "ClusterIdentifier" EndpointAccess
-> EndpointAccess -> EndpointAccess
set PropertyType "ClusterIdentifier" EndpointAccess
newValue EndpointAccess {Maybe (Value Text)
()
ValueList Text
Value Text
haddock_workaround_ :: EndpointAccess -> ()
clusterIdentifier :: EndpointAccess -> Value Text
endpointName :: EndpointAccess -> Value Text
resourceOwner :: EndpointAccess -> Maybe (Value Text)
subnetGroupName :: EndpointAccess -> Value Text
vpcSecurityGroupIds :: EndpointAccess -> ValueList Text
haddock_workaround_ :: ()
clusterIdentifier :: Value Text
endpointName :: Value Text
resourceOwner :: Maybe (Value Text)
subnetGroupName :: Value Text
vpcSecurityGroupIds :: ValueList Text
..}
    = EndpointAccess {clusterIdentifier :: Value Text
clusterIdentifier = PropertyType "ClusterIdentifier" EndpointAccess
Value Text
newValue, Maybe (Value Text)
()
ValueList Text
Value Text
haddock_workaround_ :: ()
endpointName :: Value Text
resourceOwner :: Maybe (Value Text)
subnetGroupName :: Value Text
vpcSecurityGroupIds :: ValueList Text
haddock_workaround_ :: ()
endpointName :: Value Text
resourceOwner :: Maybe (Value Text)
subnetGroupName :: Value Text
vpcSecurityGroupIds :: ValueList Text
..}
instance Property "EndpointName" EndpointAccess where
  type PropertyType "EndpointName" EndpointAccess = Value Prelude.Text
  set :: PropertyType "EndpointName" EndpointAccess
-> EndpointAccess -> EndpointAccess
set PropertyType "EndpointName" EndpointAccess
newValue EndpointAccess {Maybe (Value Text)
()
ValueList Text
Value Text
haddock_workaround_ :: EndpointAccess -> ()
clusterIdentifier :: EndpointAccess -> Value Text
endpointName :: EndpointAccess -> Value Text
resourceOwner :: EndpointAccess -> Maybe (Value Text)
subnetGroupName :: EndpointAccess -> Value Text
vpcSecurityGroupIds :: EndpointAccess -> ValueList Text
haddock_workaround_ :: ()
clusterIdentifier :: Value Text
endpointName :: Value Text
resourceOwner :: Maybe (Value Text)
subnetGroupName :: Value Text
vpcSecurityGroupIds :: ValueList Text
..}
    = EndpointAccess {endpointName :: Value Text
endpointName = PropertyType "EndpointName" EndpointAccess
Value Text
newValue, Maybe (Value Text)
()
ValueList Text
Value Text
haddock_workaround_ :: ()
clusterIdentifier :: Value Text
resourceOwner :: Maybe (Value Text)
subnetGroupName :: Value Text
vpcSecurityGroupIds :: ValueList Text
haddock_workaround_ :: ()
clusterIdentifier :: Value Text
resourceOwner :: Maybe (Value Text)
subnetGroupName :: Value Text
vpcSecurityGroupIds :: ValueList Text
..}
instance Property "ResourceOwner" EndpointAccess where
  type PropertyType "ResourceOwner" EndpointAccess = Value Prelude.Text
  set :: PropertyType "ResourceOwner" EndpointAccess
-> EndpointAccess -> EndpointAccess
set PropertyType "ResourceOwner" EndpointAccess
newValue EndpointAccess {Maybe (Value Text)
()
ValueList Text
Value Text
haddock_workaround_ :: EndpointAccess -> ()
clusterIdentifier :: EndpointAccess -> Value Text
endpointName :: EndpointAccess -> Value Text
resourceOwner :: EndpointAccess -> Maybe (Value Text)
subnetGroupName :: EndpointAccess -> Value Text
vpcSecurityGroupIds :: EndpointAccess -> ValueList Text
haddock_workaround_ :: ()
clusterIdentifier :: Value Text
endpointName :: Value Text
resourceOwner :: Maybe (Value Text)
subnetGroupName :: Value Text
vpcSecurityGroupIds :: ValueList Text
..}
    = EndpointAccess {resourceOwner :: Maybe (Value Text)
resourceOwner = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "ResourceOwner" EndpointAccess
Value Text
newValue, ()
ValueList Text
Value Text
haddock_workaround_ :: ()
clusterIdentifier :: Value Text
endpointName :: Value Text
subnetGroupName :: Value Text
vpcSecurityGroupIds :: ValueList Text
haddock_workaround_ :: ()
clusterIdentifier :: Value Text
endpointName :: Value Text
subnetGroupName :: Value Text
vpcSecurityGroupIds :: ValueList Text
..}
instance Property "SubnetGroupName" EndpointAccess where
  type PropertyType "SubnetGroupName" EndpointAccess = Value Prelude.Text
  set :: PropertyType "SubnetGroupName" EndpointAccess
-> EndpointAccess -> EndpointAccess
set PropertyType "SubnetGroupName" EndpointAccess
newValue EndpointAccess {Maybe (Value Text)
()
ValueList Text
Value Text
haddock_workaround_ :: EndpointAccess -> ()
clusterIdentifier :: EndpointAccess -> Value Text
endpointName :: EndpointAccess -> Value Text
resourceOwner :: EndpointAccess -> Maybe (Value Text)
subnetGroupName :: EndpointAccess -> Value Text
vpcSecurityGroupIds :: EndpointAccess -> ValueList Text
haddock_workaround_ :: ()
clusterIdentifier :: Value Text
endpointName :: Value Text
resourceOwner :: Maybe (Value Text)
subnetGroupName :: Value Text
vpcSecurityGroupIds :: ValueList Text
..}
    = EndpointAccess {subnetGroupName :: Value Text
subnetGroupName = PropertyType "SubnetGroupName" EndpointAccess
Value Text
newValue, Maybe (Value Text)
()
ValueList Text
Value Text
haddock_workaround_ :: ()
clusterIdentifier :: Value Text
endpointName :: Value Text
resourceOwner :: Maybe (Value Text)
vpcSecurityGroupIds :: ValueList Text
haddock_workaround_ :: ()
clusterIdentifier :: Value Text
endpointName :: Value Text
resourceOwner :: Maybe (Value Text)
vpcSecurityGroupIds :: ValueList Text
..}
instance Property "VpcSecurityGroupIds" EndpointAccess where
  type PropertyType "VpcSecurityGroupIds" EndpointAccess = ValueList Prelude.Text
  set :: PropertyType "VpcSecurityGroupIds" EndpointAccess
-> EndpointAccess -> EndpointAccess
set PropertyType "VpcSecurityGroupIds" EndpointAccess
newValue EndpointAccess {Maybe (Value Text)
()
ValueList Text
Value Text
haddock_workaround_ :: EndpointAccess -> ()
clusterIdentifier :: EndpointAccess -> Value Text
endpointName :: EndpointAccess -> Value Text
resourceOwner :: EndpointAccess -> Maybe (Value Text)
subnetGroupName :: EndpointAccess -> Value Text
vpcSecurityGroupIds :: EndpointAccess -> ValueList Text
haddock_workaround_ :: ()
clusterIdentifier :: Value Text
endpointName :: Value Text
resourceOwner :: Maybe (Value Text)
subnetGroupName :: Value Text
vpcSecurityGroupIds :: ValueList Text
..}
    = EndpointAccess {vpcSecurityGroupIds :: ValueList Text
vpcSecurityGroupIds = PropertyType "VpcSecurityGroupIds" EndpointAccess
ValueList Text
newValue, Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ()
clusterIdentifier :: Value Text
endpointName :: Value Text
resourceOwner :: Maybe (Value Text)
subnetGroupName :: Value Text
haddock_workaround_ :: ()
clusterIdentifier :: Value Text
endpointName :: Value Text
resourceOwner :: Maybe (Value Text)
subnetGroupName :: Value Text
..}