module Stratosphere.GameLift.Fleet.ServerProcessProperty (
        ServerProcessProperty(..), mkServerProcessProperty
    ) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import Stratosphere.ResourceProperties
import Stratosphere.Value
data ServerProcessProperty
  = -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-fleet-serverprocess.html>
    ServerProcessProperty {ServerProcessProperty -> ()
haddock_workaround_ :: (),
                           -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-fleet-serverprocess.html#cfn-gamelift-fleet-serverprocess-concurrentexecutions>
                           ServerProcessProperty -> Value Integer
concurrentExecutions :: (Value Prelude.Integer),
                           -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-fleet-serverprocess.html#cfn-gamelift-fleet-serverprocess-launchpath>
                           ServerProcessProperty -> Value Text
launchPath :: (Value Prelude.Text),
                           -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-fleet-serverprocess.html#cfn-gamelift-fleet-serverprocess-parameters>
                           ServerProcessProperty -> Maybe (Value Text)
parameters :: (Prelude.Maybe (Value Prelude.Text))}
  deriving stock (ServerProcessProperty -> ServerProcessProperty -> Bool
(ServerProcessProperty -> ServerProcessProperty -> Bool)
-> (ServerProcessProperty -> ServerProcessProperty -> Bool)
-> Eq ServerProcessProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: ServerProcessProperty -> ServerProcessProperty -> Bool
== :: ServerProcessProperty -> ServerProcessProperty -> Bool
$c/= :: ServerProcessProperty -> ServerProcessProperty -> Bool
/= :: ServerProcessProperty -> ServerProcessProperty -> Bool
Prelude.Eq, Int -> ServerProcessProperty -> ShowS
[ServerProcessProperty] -> ShowS
ServerProcessProperty -> String
(Int -> ServerProcessProperty -> ShowS)
-> (ServerProcessProperty -> String)
-> ([ServerProcessProperty] -> ShowS)
-> Show ServerProcessProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> ServerProcessProperty -> ShowS
showsPrec :: Int -> ServerProcessProperty -> ShowS
$cshow :: ServerProcessProperty -> String
show :: ServerProcessProperty -> String
$cshowList :: [ServerProcessProperty] -> ShowS
showList :: [ServerProcessProperty] -> ShowS
Prelude.Show)
mkServerProcessProperty ::
  Value Prelude.Integer
  -> Value Prelude.Text -> ServerProcessProperty
mkServerProcessProperty :: Value Integer -> Value Text -> ServerProcessProperty
mkServerProcessProperty Value Integer
concurrentExecutions Value Text
launchPath
  = ServerProcessProperty
      {haddock_workaround_ :: ()
haddock_workaround_ = (),
       concurrentExecutions :: Value Integer
concurrentExecutions = Value Integer
concurrentExecutions,
       launchPath :: Value Text
launchPath = Value Text
launchPath, parameters :: Maybe (Value Text)
parameters = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties ServerProcessProperty where
  toResourceProperties :: ServerProcessProperty -> ResourceProperties
toResourceProperties ServerProcessProperty {Maybe (Value Text)
()
Value Integer
Value Text
haddock_workaround_ :: ServerProcessProperty -> ()
concurrentExecutions :: ServerProcessProperty -> Value Integer
launchPath :: ServerProcessProperty -> Value Text
parameters :: ServerProcessProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
concurrentExecutions :: Value Integer
launchPath :: Value Text
parameters :: Maybe (Value Text)
..}
    = ResourceProperties
        {awsType :: Text
awsType = Text
"AWS::GameLift::Fleet.ServerProcess",
         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
"ConcurrentExecutions" Key -> Value Integer -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= Value Integer
concurrentExecutions,
                            Key
"LaunchPath" 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
launchPath]
                           ([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
"Parameters" (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)
parameters]))}
instance JSON.ToJSON ServerProcessProperty where
  toJSON :: ServerProcessProperty -> Value
toJSON ServerProcessProperty {Maybe (Value Text)
()
Value Integer
Value Text
haddock_workaround_ :: ServerProcessProperty -> ()
concurrentExecutions :: ServerProcessProperty -> Value Integer
launchPath :: ServerProcessProperty -> Value Text
parameters :: ServerProcessProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
concurrentExecutions :: Value Integer
launchPath :: Value Text
parameters :: Maybe (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
"ConcurrentExecutions" Key -> Value Integer -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= Value Integer
concurrentExecutions,
               Key
"LaunchPath" 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
launchPath]
              ([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
"Parameters" (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)
parameters])))
instance Property "ConcurrentExecutions" ServerProcessProperty where
  type PropertyType "ConcurrentExecutions" ServerProcessProperty = Value Prelude.Integer
  set :: PropertyType "ConcurrentExecutions" ServerProcessProperty
-> ServerProcessProperty -> ServerProcessProperty
set PropertyType "ConcurrentExecutions" ServerProcessProperty
newValue ServerProcessProperty {Maybe (Value Text)
()
Value Integer
Value Text
haddock_workaround_ :: ServerProcessProperty -> ()
concurrentExecutions :: ServerProcessProperty -> Value Integer
launchPath :: ServerProcessProperty -> Value Text
parameters :: ServerProcessProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
concurrentExecutions :: Value Integer
launchPath :: Value Text
parameters :: Maybe (Value Text)
..}
    = ServerProcessProperty {concurrentExecutions :: Value Integer
concurrentExecutions = PropertyType "ConcurrentExecutions" ServerProcessProperty
Value Integer
newValue, Maybe (Value Text)
()
Value Text
haddock_workaround_ :: ()
launchPath :: Value Text
parameters :: Maybe (Value Text)
haddock_workaround_ :: ()
launchPath :: Value Text
parameters :: Maybe (Value Text)
..}
instance Property "LaunchPath" ServerProcessProperty where
  type PropertyType "LaunchPath" ServerProcessProperty = Value Prelude.Text
  set :: PropertyType "LaunchPath" ServerProcessProperty
-> ServerProcessProperty -> ServerProcessProperty
set PropertyType "LaunchPath" ServerProcessProperty
newValue ServerProcessProperty {Maybe (Value Text)
()
Value Integer
Value Text
haddock_workaround_ :: ServerProcessProperty -> ()
concurrentExecutions :: ServerProcessProperty -> Value Integer
launchPath :: ServerProcessProperty -> Value Text
parameters :: ServerProcessProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
concurrentExecutions :: Value Integer
launchPath :: Value Text
parameters :: Maybe (Value Text)
..}
    = ServerProcessProperty {launchPath :: Value Text
launchPath = PropertyType "LaunchPath" ServerProcessProperty
Value Text
newValue, Maybe (Value Text)
()
Value Integer
haddock_workaround_ :: ()
concurrentExecutions :: Value Integer
parameters :: Maybe (Value Text)
haddock_workaround_ :: ()
concurrentExecutions :: Value Integer
parameters :: Maybe (Value Text)
..}
instance Property "Parameters" ServerProcessProperty where
  type PropertyType "Parameters" ServerProcessProperty = Value Prelude.Text
  set :: PropertyType "Parameters" ServerProcessProperty
-> ServerProcessProperty -> ServerProcessProperty
set PropertyType "Parameters" ServerProcessProperty
newValue ServerProcessProperty {Maybe (Value Text)
()
Value Integer
Value Text
haddock_workaround_ :: ServerProcessProperty -> ()
concurrentExecutions :: ServerProcessProperty -> Value Integer
launchPath :: ServerProcessProperty -> Value Text
parameters :: ServerProcessProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
concurrentExecutions :: Value Integer
launchPath :: Value Text
parameters :: Maybe (Value Text)
..}
    = ServerProcessProperty {parameters :: Maybe (Value Text)
parameters = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "Parameters" ServerProcessProperty
Value Text
newValue, ()
Value Integer
Value Text
haddock_workaround_ :: ()
concurrentExecutions :: Value Integer
launchPath :: Value Text
haddock_workaround_ :: ()
concurrentExecutions :: Value Integer
launchPath :: Value Text
..}