/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #pragma once #include #include #include #include #include #include namespace Aws { namespace Utils { namespace Json { class JsonValue; class JsonView; } // namespace Json } // namespace Utils namespace GameLift { namespace Model { /** *

This data type is used with the Amazon GameLift FleetIQ and game server * groups.

Properties describing a game server that is running on an * instance in a game server group.

A game server is created by a * successful call to RegisterGameServer and deleted by calling * DeregisterGameServer. A game server is claimed to host a game * session by calling ClaimGameServer.

See Also:

AWS * API Reference

*/ class GameServer { public: AWS_GAMELIFT_API GameServer(); AWS_GAMELIFT_API GameServer(Aws::Utils::Json::JsonView jsonValue); AWS_GAMELIFT_API GameServer& operator=(Aws::Utils::Json::JsonView jsonValue); AWS_GAMELIFT_API Aws::Utils::Json::JsonValue Jsonize() const; /** *

A unique identifier for the game server group where the game server is * running.

*/ inline const Aws::String& GetGameServerGroupName() const{ return m_gameServerGroupName; } /** *

A unique identifier for the game server group where the game server is * running.

*/ inline bool GameServerGroupNameHasBeenSet() const { return m_gameServerGroupNameHasBeenSet; } /** *

A unique identifier for the game server group where the game server is * running.

*/ inline void SetGameServerGroupName(const Aws::String& value) { m_gameServerGroupNameHasBeenSet = true; m_gameServerGroupName = value; } /** *

A unique identifier for the game server group where the game server is * running.

*/ inline void SetGameServerGroupName(Aws::String&& value) { m_gameServerGroupNameHasBeenSet = true; m_gameServerGroupName = std::move(value); } /** *

A unique identifier for the game server group where the game server is * running.

*/ inline void SetGameServerGroupName(const char* value) { m_gameServerGroupNameHasBeenSet = true; m_gameServerGroupName.assign(value); } /** *

A unique identifier for the game server group where the game server is * running.

*/ inline GameServer& WithGameServerGroupName(const Aws::String& value) { SetGameServerGroupName(value); return *this;} /** *

A unique identifier for the game server group where the game server is * running.

*/ inline GameServer& WithGameServerGroupName(Aws::String&& value) { SetGameServerGroupName(std::move(value)); return *this;} /** *

A unique identifier for the game server group where the game server is * running.

*/ inline GameServer& WithGameServerGroupName(const char* value) { SetGameServerGroupName(value); return *this;} /** *

The ARN identifier for the game server group where the game server is * located.

*/ inline const Aws::String& GetGameServerGroupArn() const{ return m_gameServerGroupArn; } /** *

The ARN identifier for the game server group where the game server is * located.

*/ inline bool GameServerGroupArnHasBeenSet() const { return m_gameServerGroupArnHasBeenSet; } /** *

The ARN identifier for the game server group where the game server is * located.

*/ inline void SetGameServerGroupArn(const Aws::String& value) { m_gameServerGroupArnHasBeenSet = true; m_gameServerGroupArn = value; } /** *

The ARN identifier for the game server group where the game server is * located.

*/ inline void SetGameServerGroupArn(Aws::String&& value) { m_gameServerGroupArnHasBeenSet = true; m_gameServerGroupArn = std::move(value); } /** *

The ARN identifier for the game server group where the game server is * located.

*/ inline void SetGameServerGroupArn(const char* value) { m_gameServerGroupArnHasBeenSet = true; m_gameServerGroupArn.assign(value); } /** *

The ARN identifier for the game server group where the game server is * located.

*/ inline GameServer& WithGameServerGroupArn(const Aws::String& value) { SetGameServerGroupArn(value); return *this;} /** *

The ARN identifier for the game server group where the game server is * located.

*/ inline GameServer& WithGameServerGroupArn(Aws::String&& value) { SetGameServerGroupArn(std::move(value)); return *this;} /** *

The ARN identifier for the game server group where the game server is * located.

*/ inline GameServer& WithGameServerGroupArn(const char* value) { SetGameServerGroupArn(value); return *this;} /** *

A custom string that uniquely identifies the game server. Game server IDs are * developer-defined and are unique across all game server groups in an Amazon Web * Services account.

*/ inline const Aws::String& GetGameServerId() const{ return m_gameServerId; } /** *

A custom string that uniquely identifies the game server. Game server IDs are * developer-defined and are unique across all game server groups in an Amazon Web * Services account.

*/ inline bool GameServerIdHasBeenSet() const { return m_gameServerIdHasBeenSet; } /** *

A custom string that uniquely identifies the game server. Game server IDs are * developer-defined and are unique across all game server groups in an Amazon Web * Services account.

*/ inline void SetGameServerId(const Aws::String& value) { m_gameServerIdHasBeenSet = true; m_gameServerId = value; } /** *

A custom string that uniquely identifies the game server. Game server IDs are * developer-defined and are unique across all game server groups in an Amazon Web * Services account.

*/ inline void SetGameServerId(Aws::String&& value) { m_gameServerIdHasBeenSet = true; m_gameServerId = std::move(value); } /** *

A custom string that uniquely identifies the game server. Game server IDs are * developer-defined and are unique across all game server groups in an Amazon Web * Services account.

*/ inline void SetGameServerId(const char* value) { m_gameServerIdHasBeenSet = true; m_gameServerId.assign(value); } /** *

A custom string that uniquely identifies the game server. Game server IDs are * developer-defined and are unique across all game server groups in an Amazon Web * Services account.

*/ inline GameServer& WithGameServerId(const Aws::String& value) { SetGameServerId(value); return *this;} /** *

A custom string that uniquely identifies the game server. Game server IDs are * developer-defined and are unique across all game server groups in an Amazon Web * Services account.

*/ inline GameServer& WithGameServerId(Aws::String&& value) { SetGameServerId(std::move(value)); return *this;} /** *

A custom string that uniquely identifies the game server. Game server IDs are * developer-defined and are unique across all game server groups in an Amazon Web * Services account.

*/ inline GameServer& WithGameServerId(const char* value) { SetGameServerId(value); return *this;} /** *

The unique identifier for the instance where the game server is running. This * ID is available in the instance metadata. EC2 instance IDs use a 17-character * format, for example: i-1234567890abcdef0.

*/ inline const Aws::String& GetInstanceId() const{ return m_instanceId; } /** *

The unique identifier for the instance where the game server is running. This * ID is available in the instance metadata. EC2 instance IDs use a 17-character * format, for example: i-1234567890abcdef0.

*/ inline bool InstanceIdHasBeenSet() const { return m_instanceIdHasBeenSet; } /** *

The unique identifier for the instance where the game server is running. This * ID is available in the instance metadata. EC2 instance IDs use a 17-character * format, for example: i-1234567890abcdef0.

*/ inline void SetInstanceId(const Aws::String& value) { m_instanceIdHasBeenSet = true; m_instanceId = value; } /** *

The unique identifier for the instance where the game server is running. This * ID is available in the instance metadata. EC2 instance IDs use a 17-character * format, for example: i-1234567890abcdef0.

*/ inline void SetInstanceId(Aws::String&& value) { m_instanceIdHasBeenSet = true; m_instanceId = std::move(value); } /** *

The unique identifier for the instance where the game server is running. This * ID is available in the instance metadata. EC2 instance IDs use a 17-character * format, for example: i-1234567890abcdef0.

*/ inline void SetInstanceId(const char* value) { m_instanceIdHasBeenSet = true; m_instanceId.assign(value); } /** *

The unique identifier for the instance where the game server is running. This * ID is available in the instance metadata. EC2 instance IDs use a 17-character * format, for example: i-1234567890abcdef0.

*/ inline GameServer& WithInstanceId(const Aws::String& value) { SetInstanceId(value); return *this;} /** *

The unique identifier for the instance where the game server is running. This * ID is available in the instance metadata. EC2 instance IDs use a 17-character * format, for example: i-1234567890abcdef0.

*/ inline GameServer& WithInstanceId(Aws::String&& value) { SetInstanceId(std::move(value)); return *this;} /** *

The unique identifier for the instance where the game server is running. This * ID is available in the instance metadata. EC2 instance IDs use a 17-character * format, for example: i-1234567890abcdef0.

*/ inline GameServer& WithInstanceId(const char* value) { SetInstanceId(value); return *this;} /** *

The port and IP address that must be used to establish a client connection to * the game server.

*/ inline const Aws::String& GetConnectionInfo() const{ return m_connectionInfo; } /** *

The port and IP address that must be used to establish a client connection to * the game server.

*/ inline bool ConnectionInfoHasBeenSet() const { return m_connectionInfoHasBeenSet; } /** *

The port and IP address that must be used to establish a client connection to * the game server.

*/ inline void SetConnectionInfo(const Aws::String& value) { m_connectionInfoHasBeenSet = true; m_connectionInfo = value; } /** *

The port and IP address that must be used to establish a client connection to * the game server.

*/ inline void SetConnectionInfo(Aws::String&& value) { m_connectionInfoHasBeenSet = true; m_connectionInfo = std::move(value); } /** *

The port and IP address that must be used to establish a client connection to * the game server.

*/ inline void SetConnectionInfo(const char* value) { m_connectionInfoHasBeenSet = true; m_connectionInfo.assign(value); } /** *

The port and IP address that must be used to establish a client connection to * the game server.

*/ inline GameServer& WithConnectionInfo(const Aws::String& value) { SetConnectionInfo(value); return *this;} /** *

The port and IP address that must be used to establish a client connection to * the game server.

*/ inline GameServer& WithConnectionInfo(Aws::String&& value) { SetConnectionInfo(std::move(value)); return *this;} /** *

The port and IP address that must be used to establish a client connection to * the game server.

*/ inline GameServer& WithConnectionInfo(const char* value) { SetConnectionInfo(value); return *this;} /** *

A set of custom game server properties, formatted as a single string value. * This data is passed to a game client or service when it requests information on * game servers.

*/ inline const Aws::String& GetGameServerData() const{ return m_gameServerData; } /** *

A set of custom game server properties, formatted as a single string value. * This data is passed to a game client or service when it requests information on * game servers.

*/ inline bool GameServerDataHasBeenSet() const { return m_gameServerDataHasBeenSet; } /** *

A set of custom game server properties, formatted as a single string value. * This data is passed to a game client or service when it requests information on * game servers.

*/ inline void SetGameServerData(const Aws::String& value) { m_gameServerDataHasBeenSet = true; m_gameServerData = value; } /** *

A set of custom game server properties, formatted as a single string value. * This data is passed to a game client or service when it requests information on * game servers.

*/ inline void SetGameServerData(Aws::String&& value) { m_gameServerDataHasBeenSet = true; m_gameServerData = std::move(value); } /** *

A set of custom game server properties, formatted as a single string value. * This data is passed to a game client or service when it requests information on * game servers.

*/ inline void SetGameServerData(const char* value) { m_gameServerDataHasBeenSet = true; m_gameServerData.assign(value); } /** *

A set of custom game server properties, formatted as a single string value. * This data is passed to a game client or service when it requests information on * game servers.

*/ inline GameServer& WithGameServerData(const Aws::String& value) { SetGameServerData(value); return *this;} /** *

A set of custom game server properties, formatted as a single string value. * This data is passed to a game client or service when it requests information on * game servers.

*/ inline GameServer& WithGameServerData(Aws::String&& value) { SetGameServerData(std::move(value)); return *this;} /** *

A set of custom game server properties, formatted as a single string value. * This data is passed to a game client or service when it requests information on * game servers.

*/ inline GameServer& WithGameServerData(const char* value) { SetGameServerData(value); return *this;} /** *

Indicates when an available game server has been reserved for gameplay but * has not yet started hosting a game. Once it is claimed, the game server remains * in CLAIMED status for a maximum of one minute. During this time, * game clients connect to the game server to start the game and trigger the game * server to update its utilization status. After one minute, the game server claim * status reverts to null.

*/ inline const GameServerClaimStatus& GetClaimStatus() const{ return m_claimStatus; } /** *

Indicates when an available game server has been reserved for gameplay but * has not yet started hosting a game. Once it is claimed, the game server remains * in CLAIMED status for a maximum of one minute. During this time, * game clients connect to the game server to start the game and trigger the game * server to update its utilization status. After one minute, the game server claim * status reverts to null.

*/ inline bool ClaimStatusHasBeenSet() const { return m_claimStatusHasBeenSet; } /** *

Indicates when an available game server has been reserved for gameplay but * has not yet started hosting a game. Once it is claimed, the game server remains * in CLAIMED status for a maximum of one minute. During this time, * game clients connect to the game server to start the game and trigger the game * server to update its utilization status. After one minute, the game server claim * status reverts to null.

*/ inline void SetClaimStatus(const GameServerClaimStatus& value) { m_claimStatusHasBeenSet = true; m_claimStatus = value; } /** *

Indicates when an available game server has been reserved for gameplay but * has not yet started hosting a game. Once it is claimed, the game server remains * in CLAIMED status for a maximum of one minute. During this time, * game clients connect to the game server to start the game and trigger the game * server to update its utilization status. After one minute, the game server claim * status reverts to null.

*/ inline void SetClaimStatus(GameServerClaimStatus&& value) { m_claimStatusHasBeenSet = true; m_claimStatus = std::move(value); } /** *

Indicates when an available game server has been reserved for gameplay but * has not yet started hosting a game. Once it is claimed, the game server remains * in CLAIMED status for a maximum of one minute. During this time, * game clients connect to the game server to start the game and trigger the game * server to update its utilization status. After one minute, the game server claim * status reverts to null.

*/ inline GameServer& WithClaimStatus(const GameServerClaimStatus& value) { SetClaimStatus(value); return *this;} /** *

Indicates when an available game server has been reserved for gameplay but * has not yet started hosting a game. Once it is claimed, the game server remains * in CLAIMED status for a maximum of one minute. During this time, * game clients connect to the game server to start the game and trigger the game * server to update its utilization status. After one minute, the game server claim * status reverts to null.

*/ inline GameServer& WithClaimStatus(GameServerClaimStatus&& value) { SetClaimStatus(std::move(value)); return *this;} /** *

Indicates whether the game server is currently available for new games or is * busy. Possible statuses include:

  • AVAILABLE - The * game server is available to be claimed. A game server that has been claimed * remains in this status until it reports game hosting activity.

  • *

    UTILIZED - The game server is currently hosting a game session * with players.

*/ inline const GameServerUtilizationStatus& GetUtilizationStatus() const{ return m_utilizationStatus; } /** *

Indicates whether the game server is currently available for new games or is * busy. Possible statuses include:

  • AVAILABLE - The * game server is available to be claimed. A game server that has been claimed * remains in this status until it reports game hosting activity.

  • *

    UTILIZED - The game server is currently hosting a game session * with players.

*/ inline bool UtilizationStatusHasBeenSet() const { return m_utilizationStatusHasBeenSet; } /** *

Indicates whether the game server is currently available for new games or is * busy. Possible statuses include:

  • AVAILABLE - The * game server is available to be claimed. A game server that has been claimed * remains in this status until it reports game hosting activity.

  • *

    UTILIZED - The game server is currently hosting a game session * with players.

*/ inline void SetUtilizationStatus(const GameServerUtilizationStatus& value) { m_utilizationStatusHasBeenSet = true; m_utilizationStatus = value; } /** *

Indicates whether the game server is currently available for new games or is * busy. Possible statuses include:

  • AVAILABLE - The * game server is available to be claimed. A game server that has been claimed * remains in this status until it reports game hosting activity.

  • *

    UTILIZED - The game server is currently hosting a game session * with players.

*/ inline void SetUtilizationStatus(GameServerUtilizationStatus&& value) { m_utilizationStatusHasBeenSet = true; m_utilizationStatus = std::move(value); } /** *

Indicates whether the game server is currently available for new games or is * busy. Possible statuses include:

  • AVAILABLE - The * game server is available to be claimed. A game server that has been claimed * remains in this status until it reports game hosting activity.

  • *

    UTILIZED - The game server is currently hosting a game session * with players.

*/ inline GameServer& WithUtilizationStatus(const GameServerUtilizationStatus& value) { SetUtilizationStatus(value); return *this;} /** *

Indicates whether the game server is currently available for new games or is * busy. Possible statuses include:

  • AVAILABLE - The * game server is available to be claimed. A game server that has been claimed * remains in this status until it reports game hosting activity.

  • *

    UTILIZED - The game server is currently hosting a game session * with players.

*/ inline GameServer& WithUtilizationStatus(GameServerUtilizationStatus&& value) { SetUtilizationStatus(std::move(value)); return *this;} /** *

Timestamp that indicates when the game server registered. The format is a * number expressed in Unix time as milliseconds (for example * "1469498468.057").

*/ inline const Aws::Utils::DateTime& GetRegistrationTime() const{ return m_registrationTime; } /** *

Timestamp that indicates when the game server registered. The format is a * number expressed in Unix time as milliseconds (for example * "1469498468.057").

*/ inline bool RegistrationTimeHasBeenSet() const { return m_registrationTimeHasBeenSet; } /** *

Timestamp that indicates when the game server registered. The format is a * number expressed in Unix time as milliseconds (for example * "1469498468.057").

*/ inline void SetRegistrationTime(const Aws::Utils::DateTime& value) { m_registrationTimeHasBeenSet = true; m_registrationTime = value; } /** *

Timestamp that indicates when the game server registered. The format is a * number expressed in Unix time as milliseconds (for example * "1469498468.057").

*/ inline void SetRegistrationTime(Aws::Utils::DateTime&& value) { m_registrationTimeHasBeenSet = true; m_registrationTime = std::move(value); } /** *

Timestamp that indicates when the game server registered. The format is a * number expressed in Unix time as milliseconds (for example * "1469498468.057").

*/ inline GameServer& WithRegistrationTime(const Aws::Utils::DateTime& value) { SetRegistrationTime(value); return *this;} /** *

Timestamp that indicates when the game server registered. The format is a * number expressed in Unix time as milliseconds (for example * "1469498468.057").

*/ inline GameServer& WithRegistrationTime(Aws::Utils::DateTime&& value) { SetRegistrationTime(std::move(value)); return *this;} /** *

Timestamp that indicates the last time the game server was claimed. The * format is a number expressed in Unix time as milliseconds (for example * "1469498468.057"). This value is used to calculate when a claimed * game server's status should revert to null.

*/ inline const Aws::Utils::DateTime& GetLastClaimTime() const{ return m_lastClaimTime; } /** *

Timestamp that indicates the last time the game server was claimed. The * format is a number expressed in Unix time as milliseconds (for example * "1469498468.057"). This value is used to calculate when a claimed * game server's status should revert to null.

*/ inline bool LastClaimTimeHasBeenSet() const { return m_lastClaimTimeHasBeenSet; } /** *

Timestamp that indicates the last time the game server was claimed. The * format is a number expressed in Unix time as milliseconds (for example * "1469498468.057"). This value is used to calculate when a claimed * game server's status should revert to null.

*/ inline void SetLastClaimTime(const Aws::Utils::DateTime& value) { m_lastClaimTimeHasBeenSet = true; m_lastClaimTime = value; } /** *

Timestamp that indicates the last time the game server was claimed. The * format is a number expressed in Unix time as milliseconds (for example * "1469498468.057"). This value is used to calculate when a claimed * game server's status should revert to null.

*/ inline void SetLastClaimTime(Aws::Utils::DateTime&& value) { m_lastClaimTimeHasBeenSet = true; m_lastClaimTime = std::move(value); } /** *

Timestamp that indicates the last time the game server was claimed. The * format is a number expressed in Unix time as milliseconds (for example * "1469498468.057"). This value is used to calculate when a claimed * game server's status should revert to null.

*/ inline GameServer& WithLastClaimTime(const Aws::Utils::DateTime& value) { SetLastClaimTime(value); return *this;} /** *

Timestamp that indicates the last time the game server was claimed. The * format is a number expressed in Unix time as milliseconds (for example * "1469498468.057"). This value is used to calculate when a claimed * game server's status should revert to null.

*/ inline GameServer& WithLastClaimTime(Aws::Utils::DateTime&& value) { SetLastClaimTime(std::move(value)); return *this;} /** *

Timestamp that indicates the last time the game server was updated with * health status. The format is a number expressed in Unix time as milliseconds * (for example "1469498468.057"). After game server registration, * this property is only changed when a game server update specifies a health check * value.

*/ inline const Aws::Utils::DateTime& GetLastHealthCheckTime() const{ return m_lastHealthCheckTime; } /** *

Timestamp that indicates the last time the game server was updated with * health status. The format is a number expressed in Unix time as milliseconds * (for example "1469498468.057"). After game server registration, * this property is only changed when a game server update specifies a health check * value.

*/ inline bool LastHealthCheckTimeHasBeenSet() const { return m_lastHealthCheckTimeHasBeenSet; } /** *

Timestamp that indicates the last time the game server was updated with * health status. The format is a number expressed in Unix time as milliseconds * (for example "1469498468.057"). After game server registration, * this property is only changed when a game server update specifies a health check * value.

*/ inline void SetLastHealthCheckTime(const Aws::Utils::DateTime& value) { m_lastHealthCheckTimeHasBeenSet = true; m_lastHealthCheckTime = value; } /** *

Timestamp that indicates the last time the game server was updated with * health status. The format is a number expressed in Unix time as milliseconds * (for example "1469498468.057"). After game server registration, * this property is only changed when a game server update specifies a health check * value.

*/ inline void SetLastHealthCheckTime(Aws::Utils::DateTime&& value) { m_lastHealthCheckTimeHasBeenSet = true; m_lastHealthCheckTime = std::move(value); } /** *

Timestamp that indicates the last time the game server was updated with * health status. The format is a number expressed in Unix time as milliseconds * (for example "1469498468.057"). After game server registration, * this property is only changed when a game server update specifies a health check * value.

*/ inline GameServer& WithLastHealthCheckTime(const Aws::Utils::DateTime& value) { SetLastHealthCheckTime(value); return *this;} /** *

Timestamp that indicates the last time the game server was updated with * health status. The format is a number expressed in Unix time as milliseconds * (for example "1469498468.057"). After game server registration, * this property is only changed when a game server update specifies a health check * value.

*/ inline GameServer& WithLastHealthCheckTime(Aws::Utils::DateTime&& value) { SetLastHealthCheckTime(std::move(value)); return *this;} private: Aws::String m_gameServerGroupName; bool m_gameServerGroupNameHasBeenSet = false; Aws::String m_gameServerGroupArn; bool m_gameServerGroupArnHasBeenSet = false; Aws::String m_gameServerId; bool m_gameServerIdHasBeenSet = false; Aws::String m_instanceId; bool m_instanceIdHasBeenSet = false; Aws::String m_connectionInfo; bool m_connectionInfoHasBeenSet = false; Aws::String m_gameServerData; bool m_gameServerDataHasBeenSet = false; GameServerClaimStatus m_claimStatus; bool m_claimStatusHasBeenSet = false; GameServerUtilizationStatus m_utilizationStatus; bool m_utilizationStatusHasBeenSet = false; Aws::Utils::DateTime m_registrationTime; bool m_registrationTimeHasBeenSet = false; Aws::Utils::DateTime m_lastClaimTime; bool m_lastClaimTimeHasBeenSet = false; Aws::Utils::DateTime m_lastHealthCheckTime; bool m_lastHealthCheckTimeHasBeenSet = false; }; } // namespace Model } // namespace GameLift } // namespace Aws