module Stratosphere.GameLift.Build.StorageLocationProperty (
        StorageLocationProperty(..), mkStorageLocationProperty
    ) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import Stratosphere.ResourceProperties
import Stratosphere.Value
data StorageLocationProperty
  = -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-build-storagelocation.html>
    StorageLocationProperty {StorageLocationProperty -> ()
haddock_workaround_ :: (),
                             -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-build-storagelocation.html#cfn-gamelift-build-storagelocation-bucket>
                             StorageLocationProperty -> Value Text
bucket :: (Value Prelude.Text),
                             -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-build-storagelocation.html#cfn-gamelift-build-storagelocation-key>
                             StorageLocationProperty -> Value Text
key :: (Value Prelude.Text),
                             -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-build-storagelocation.html#cfn-gamelift-build-storagelocation-objectversion>
                             StorageLocationProperty -> Maybe (Value Text)
objectVersion :: (Prelude.Maybe (Value Prelude.Text)),
                             -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-build-storagelocation.html#cfn-gamelift-build-storagelocation-rolearn>
                             StorageLocationProperty -> Value Text
roleArn :: (Value Prelude.Text)}
  deriving stock (StorageLocationProperty -> StorageLocationProperty -> Bool
(StorageLocationProperty -> StorageLocationProperty -> Bool)
-> (StorageLocationProperty -> StorageLocationProperty -> Bool)
-> Eq StorageLocationProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: StorageLocationProperty -> StorageLocationProperty -> Bool
== :: StorageLocationProperty -> StorageLocationProperty -> Bool
$c/= :: StorageLocationProperty -> StorageLocationProperty -> Bool
/= :: StorageLocationProperty -> StorageLocationProperty -> Bool
Prelude.Eq, Int -> StorageLocationProperty -> ShowS
[StorageLocationProperty] -> ShowS
StorageLocationProperty -> String
(Int -> StorageLocationProperty -> ShowS)
-> (StorageLocationProperty -> String)
-> ([StorageLocationProperty] -> ShowS)
-> Show StorageLocationProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> StorageLocationProperty -> ShowS
showsPrec :: Int -> StorageLocationProperty -> ShowS
$cshow :: StorageLocationProperty -> String
show :: StorageLocationProperty -> String
$cshowList :: [StorageLocationProperty] -> ShowS
showList :: [StorageLocationProperty] -> ShowS
Prelude.Show)
mkStorageLocationProperty ::
  Value Prelude.Text
  -> Value Prelude.Text
     -> Value Prelude.Text -> StorageLocationProperty
mkStorageLocationProperty :: Value Text -> Value Text -> Value Text -> StorageLocationProperty
mkStorageLocationProperty Value Text
bucket Value Text
key Value Text
roleArn
  = StorageLocationProperty
      {haddock_workaround_ :: ()
haddock_workaround_ = (), bucket :: Value Text
bucket = Value Text
bucket, key :: Value Text
key = Value Text
key,
       roleArn :: Value Text
roleArn = Value Text
roleArn, objectVersion :: Maybe (Value Text)
objectVersion = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties StorageLocationProperty where
  toResourceProperties :: StorageLocationProperty -> ResourceProperties
toResourceProperties StorageLocationProperty {Maybe (Value Text)
()
Value Text
haddock_workaround_ :: StorageLocationProperty -> ()
bucket :: StorageLocationProperty -> Value Text
key :: StorageLocationProperty -> Value Text
objectVersion :: StorageLocationProperty -> Maybe (Value Text)
roleArn :: StorageLocationProperty -> Value Text
haddock_workaround_ :: ()
bucket :: Value Text
key :: Value Text
objectVersion :: Maybe (Value Text)
roleArn :: Value Text
..}
    = ResourceProperties
        {awsType :: Text
awsType = Text
"AWS::GameLift::Build.StorageLocation",
         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
"Bucket" 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
bucket, Key
"Key" 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
key,
                            Key
"RoleArn" 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
roleArn]
                           ([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
"ObjectVersion" (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)
objectVersion]))}
instance JSON.ToJSON StorageLocationProperty where
  toJSON :: StorageLocationProperty -> Value
toJSON StorageLocationProperty {Maybe (Value Text)
()
Value Text
haddock_workaround_ :: StorageLocationProperty -> ()
bucket :: StorageLocationProperty -> Value Text
key :: StorageLocationProperty -> Value Text
objectVersion :: StorageLocationProperty -> Maybe (Value Text)
roleArn :: StorageLocationProperty -> Value Text
haddock_workaround_ :: ()
bucket :: Value Text
key :: Value Text
objectVersion :: Maybe (Value Text)
roleArn :: Value 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
"Bucket" 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
bucket, Key
"Key" 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
key,
               Key
"RoleArn" 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
roleArn]
              ([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
"ObjectVersion" (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)
objectVersion])))
instance Property "Bucket" StorageLocationProperty where
  type PropertyType "Bucket" StorageLocationProperty = Value Prelude.Text
  set :: PropertyType "Bucket" StorageLocationProperty
-> StorageLocationProperty -> StorageLocationProperty
set PropertyType "Bucket" StorageLocationProperty
newValue StorageLocationProperty {Maybe (Value Text)
()
Value Text
haddock_workaround_ :: StorageLocationProperty -> ()
bucket :: StorageLocationProperty -> Value Text
key :: StorageLocationProperty -> Value Text
objectVersion :: StorageLocationProperty -> Maybe (Value Text)
roleArn :: StorageLocationProperty -> Value Text
haddock_workaround_ :: ()
bucket :: Value Text
key :: Value Text
objectVersion :: Maybe (Value Text)
roleArn :: Value Text
..}
    = StorageLocationProperty {bucket :: Value Text
bucket = PropertyType "Bucket" StorageLocationProperty
Value Text
newValue, Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ()
key :: Value Text
objectVersion :: Maybe (Value Text)
roleArn :: Value Text
haddock_workaround_ :: ()
key :: Value Text
objectVersion :: Maybe (Value Text)
roleArn :: Value Text
..}
instance Property "Key" StorageLocationProperty where
  type PropertyType "Key" StorageLocationProperty = Value Prelude.Text
  set :: PropertyType "Key" StorageLocationProperty
-> StorageLocationProperty -> StorageLocationProperty
set PropertyType "Key" StorageLocationProperty
newValue StorageLocationProperty {Maybe (Value Text)
()
Value Text
haddock_workaround_ :: StorageLocationProperty -> ()
bucket :: StorageLocationProperty -> Value Text
key :: StorageLocationProperty -> Value Text
objectVersion :: StorageLocationProperty -> Maybe (Value Text)
roleArn :: StorageLocationProperty -> Value Text
haddock_workaround_ :: ()
bucket :: Value Text
key :: Value Text
objectVersion :: Maybe (Value Text)
roleArn :: Value Text
..}
    = StorageLocationProperty {key :: Value Text
key = PropertyType "Key" StorageLocationProperty
Value Text
newValue, Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ()
bucket :: Value Text
objectVersion :: Maybe (Value Text)
roleArn :: Value Text
haddock_workaround_ :: ()
bucket :: Value Text
objectVersion :: Maybe (Value Text)
roleArn :: Value Text
..}
instance Property "ObjectVersion" StorageLocationProperty where
  type PropertyType "ObjectVersion" StorageLocationProperty = Value Prelude.Text
  set :: PropertyType "ObjectVersion" StorageLocationProperty
-> StorageLocationProperty -> StorageLocationProperty
set PropertyType "ObjectVersion" StorageLocationProperty
newValue StorageLocationProperty {Maybe (Value Text)
()
Value Text
haddock_workaround_ :: StorageLocationProperty -> ()
bucket :: StorageLocationProperty -> Value Text
key :: StorageLocationProperty -> Value Text
objectVersion :: StorageLocationProperty -> Maybe (Value Text)
roleArn :: StorageLocationProperty -> Value Text
haddock_workaround_ :: ()
bucket :: Value Text
key :: Value Text
objectVersion :: Maybe (Value Text)
roleArn :: Value Text
..}
    = StorageLocationProperty
        {objectVersion :: Maybe (Value Text)
objectVersion = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "ObjectVersion" StorageLocationProperty
Value Text
newValue, ()
Value Text
haddock_workaround_ :: ()
bucket :: Value Text
key :: Value Text
roleArn :: Value Text
haddock_workaround_ :: ()
bucket :: Value Text
key :: Value Text
roleArn :: Value Text
..}
instance Property "RoleArn" StorageLocationProperty where
  type PropertyType "RoleArn" StorageLocationProperty = Value Prelude.Text
  set :: PropertyType "RoleArn" StorageLocationProperty
-> StorageLocationProperty -> StorageLocationProperty
set PropertyType "RoleArn" StorageLocationProperty
newValue StorageLocationProperty {Maybe (Value Text)
()
Value Text
haddock_workaround_ :: StorageLocationProperty -> ()
bucket :: StorageLocationProperty -> Value Text
key :: StorageLocationProperty -> Value Text
objectVersion :: StorageLocationProperty -> Maybe (Value Text)
roleArn :: StorageLocationProperty -> Value Text
haddock_workaround_ :: ()
bucket :: Value Text
key :: Value Text
objectVersion :: Maybe (Value Text)
roleArn :: Value Text
..}
    = StorageLocationProperty {roleArn :: Value Text
roleArn = PropertyType "RoleArn" StorageLocationProperty
Value Text
newValue, Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ()
bucket :: Value Text
key :: Value Text
objectVersion :: Maybe (Value Text)
haddock_workaround_ :: ()
bucket :: Value Text
key :: Value Text
objectVersion :: Maybe (Value Text)
..}