/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include An Amazon GameLift compute resource for hosting your game servers. Computes
* in an Amazon GameLift fleet differs depending on the fleet's compute type
* property as follows: For managed EC2 fleets, a compute is an
* EC2 instance. For Anywhere fleets, a compute is a computing
* resource that you provide and is registered to the fleet.
See Also:
AWS
* API Reference
A unique identifier for the fleet that the compute belongs to.
*/ inline const Aws::String& GetFleetId() const{ return m_fleetId; } inline bool FleetIdHasBeenSet() const { return m_fleetIdHasBeenSet; } inline void SetFleetId(const Aws::String& value) { m_fleetIdHasBeenSet = true; m_fleetId = value; } inline void SetFleetId(Aws::String&& value) { m_fleetIdHasBeenSet = true; m_fleetId = std::move(value); } inline void SetFleetId(const char* value) { m_fleetIdHasBeenSet = true; m_fleetId.assign(value); } inline Compute& WithFleetId(const Aws::String& value) { SetFleetId(value); return *this;} inline Compute& WithFleetId(Aws::String&& value) { SetFleetId(std::move(value)); return *this;} inline Compute& WithFleetId(const char* value) { SetFleetId(value); return *this;} ///@} ///@{ /** *The Amazon Resource Name (ARN) of the fleet that the compute belongs to.
*/ inline const Aws::String& GetFleetArn() const{ return m_fleetArn; } inline bool FleetArnHasBeenSet() const { return m_fleetArnHasBeenSet; } inline void SetFleetArn(const Aws::String& value) { m_fleetArnHasBeenSet = true; m_fleetArn = value; } inline void SetFleetArn(Aws::String&& value) { m_fleetArnHasBeenSet = true; m_fleetArn = std::move(value); } inline void SetFleetArn(const char* value) { m_fleetArnHasBeenSet = true; m_fleetArn.assign(value); } inline Compute& WithFleetArn(const Aws::String& value) { SetFleetArn(value); return *this;} inline Compute& WithFleetArn(Aws::String&& value) { SetFleetArn(std::move(value)); return *this;} inline Compute& WithFleetArn(const char* value) { SetFleetArn(value); return *this;} ///@} ///@{ /** *A descriptive label for the compute resource. For instances in a managed EC2
* fleet, the compute name is the same value as the InstanceId ID.
The ARN that is assigned to a compute resource and uniquely identifies it. * ARNs are unique across locations. Instances in managed EC2 fleets are not * assigned a Compute ARN.
*/ inline const Aws::String& GetComputeArn() const{ return m_computeArn; } inline bool ComputeArnHasBeenSet() const { return m_computeArnHasBeenSet; } inline void SetComputeArn(const Aws::String& value) { m_computeArnHasBeenSet = true; m_computeArn = value; } inline void SetComputeArn(Aws::String&& value) { m_computeArnHasBeenSet = true; m_computeArn = std::move(value); } inline void SetComputeArn(const char* value) { m_computeArnHasBeenSet = true; m_computeArn.assign(value); } inline Compute& WithComputeArn(const Aws::String& value) { SetComputeArn(value); return *this;} inline Compute& WithComputeArn(Aws::String&& value) { SetComputeArn(std::move(value)); return *this;} inline Compute& WithComputeArn(const char* value) { SetComputeArn(value); return *this;} ///@} ///@{ /** *The IP address of a compute resource. Amazon GameLift requires a DNS name or * IP address for a compute.
*/ inline const Aws::String& GetIpAddress() const{ return m_ipAddress; } inline bool IpAddressHasBeenSet() const { return m_ipAddressHasBeenSet; } inline void SetIpAddress(const Aws::String& value) { m_ipAddressHasBeenSet = true; m_ipAddress = value; } inline void SetIpAddress(Aws::String&& value) { m_ipAddressHasBeenSet = true; m_ipAddress = std::move(value); } inline void SetIpAddress(const char* value) { m_ipAddressHasBeenSet = true; m_ipAddress.assign(value); } inline Compute& WithIpAddress(const Aws::String& value) { SetIpAddress(value); return *this;} inline Compute& WithIpAddress(Aws::String&& value) { SetIpAddress(std::move(value)); return *this;} inline Compute& WithIpAddress(const char* value) { SetIpAddress(value); return *this;} ///@} ///@{ /** *The DNS name of a compute resource. Amazon GameLift requires a DNS name or IP * address for a compute.
*/ inline const Aws::String& GetDnsName() const{ return m_dnsName; } inline bool DnsNameHasBeenSet() const { return m_dnsNameHasBeenSet; } inline void SetDnsName(const Aws::String& value) { m_dnsNameHasBeenSet = true; m_dnsName = value; } inline void SetDnsName(Aws::String&& value) { m_dnsNameHasBeenSet = true; m_dnsName = std::move(value); } inline void SetDnsName(const char* value) { m_dnsNameHasBeenSet = true; m_dnsName.assign(value); } inline Compute& WithDnsName(const Aws::String& value) { SetDnsName(value); return *this;} inline Compute& WithDnsName(Aws::String&& value) { SetDnsName(std::move(value)); return *this;} inline Compute& WithDnsName(const char* value) { SetDnsName(value); return *this;} ///@} ///@{ /** *Current status of the compute. A compute must have an ACTIVE
* status to host game sessions.
The name of the custom location you added to the fleet that this compute * resource resides in.
*/ inline const Aws::String& GetLocation() const{ return m_location; } inline bool LocationHasBeenSet() const { return m_locationHasBeenSet; } inline void SetLocation(const Aws::String& value) { m_locationHasBeenSet = true; m_location = value; } inline void SetLocation(Aws::String&& value) { m_locationHasBeenSet = true; m_location = std::move(value); } inline void SetLocation(const char* value) { m_locationHasBeenSet = true; m_location.assign(value); } inline Compute& WithLocation(const Aws::String& value) { SetLocation(value); return *this;} inline Compute& WithLocation(Aws::String&& value) { SetLocation(std::move(value)); return *this;} inline Compute& WithLocation(const char* value) { SetLocation(value); return *this;} ///@} ///@{ /** *A time stamp indicating when this data object was created. Format is a number
* expressed in Unix time as milliseconds (for example
* "1469498468.057").
The type of operating system on the compute resource.
Amazon * Linux 2 (AL2) will reach end of support on 6/30/2025. See more details in the Amazon Linux 2 FAQs. For * game servers that are hosted on AL2 and use Amazon GameLift server SDK 4.x., * first update the game server build to server SDK 5.x, and then deploy to AL2023 * instances. See * Migrate to Amazon GameLift server SDK version 5.
*/ inline const OperatingSystem& GetOperatingSystem() const{ return m_operatingSystem; } inline bool OperatingSystemHasBeenSet() const { return m_operatingSystemHasBeenSet; } inline void SetOperatingSystem(const OperatingSystem& value) { m_operatingSystemHasBeenSet = true; m_operatingSystem = value; } inline void SetOperatingSystem(OperatingSystem&& value) { m_operatingSystemHasBeenSet = true; m_operatingSystem = std::move(value); } inline Compute& WithOperatingSystem(const OperatingSystem& value) { SetOperatingSystem(value); return *this;} inline Compute& WithOperatingSystem(OperatingSystem&& value) { SetOperatingSystem(std::move(value)); return *this;} ///@} ///@{ /** *The Amazon EC2 instance type that the fleet uses. For registered computes in * an Amazon GameLift Anywhere fleet, this property is empty.
*/ inline const EC2InstanceType& GetType() const{ return m_type; } inline bool TypeHasBeenSet() const { return m_typeHasBeenSet; } inline void SetType(const EC2InstanceType& value) { m_typeHasBeenSet = true; m_type = value; } inline void SetType(EC2InstanceType&& value) { m_typeHasBeenSet = true; m_type = std::move(value); } inline Compute& WithType(const EC2InstanceType& value) { SetType(value); return *this;} inline Compute& WithType(EC2InstanceType&& value) { SetType(std::move(value)); return *this;} ///@} ///@{ /** *The Amazon GameLift SDK endpoint connection for a registered compute resource * in an Anywhere fleet. The game servers on the compute use this endpoint to * connect to the Amazon GameLift service.
*/ inline const Aws::String& GetGameLiftServiceSdkEndpoint() const{ return m_gameLiftServiceSdkEndpoint; } inline bool GameLiftServiceSdkEndpointHasBeenSet() const { return m_gameLiftServiceSdkEndpointHasBeenSet; } inline void SetGameLiftServiceSdkEndpoint(const Aws::String& value) { m_gameLiftServiceSdkEndpointHasBeenSet = true; m_gameLiftServiceSdkEndpoint = value; } inline void SetGameLiftServiceSdkEndpoint(Aws::String&& value) { m_gameLiftServiceSdkEndpointHasBeenSet = true; m_gameLiftServiceSdkEndpoint = std::move(value); } inline void SetGameLiftServiceSdkEndpoint(const char* value) { m_gameLiftServiceSdkEndpointHasBeenSet = true; m_gameLiftServiceSdkEndpoint.assign(value); } inline Compute& WithGameLiftServiceSdkEndpoint(const Aws::String& value) { SetGameLiftServiceSdkEndpoint(value); return *this;} inline Compute& WithGameLiftServiceSdkEndpoint(Aws::String&& value) { SetGameLiftServiceSdkEndpoint(std::move(value)); return *this;} inline Compute& WithGameLiftServiceSdkEndpoint(const char* value) { SetGameLiftServiceSdkEndpoint(value); return *this;} ///@} ///@{ /** *The endpoint of the Amazon GameLift Agent.
*/ inline const Aws::String& GetGameLiftAgentEndpoint() const{ return m_gameLiftAgentEndpoint; } inline bool GameLiftAgentEndpointHasBeenSet() const { return m_gameLiftAgentEndpointHasBeenSet; } inline void SetGameLiftAgentEndpoint(const Aws::String& value) { m_gameLiftAgentEndpointHasBeenSet = true; m_gameLiftAgentEndpoint = value; } inline void SetGameLiftAgentEndpoint(Aws::String&& value) { m_gameLiftAgentEndpointHasBeenSet = true; m_gameLiftAgentEndpoint = std::move(value); } inline void SetGameLiftAgentEndpoint(const char* value) { m_gameLiftAgentEndpointHasBeenSet = true; m_gameLiftAgentEndpoint.assign(value); } inline Compute& WithGameLiftAgentEndpoint(const Aws::String& value) { SetGameLiftAgentEndpoint(value); return *this;} inline Compute& WithGameLiftAgentEndpoint(Aws::String&& value) { SetGameLiftAgentEndpoint(std::move(value)); return *this;} inline Compute& WithGameLiftAgentEndpoint(const char* value) { SetGameLiftAgentEndpoint(value); return *this;} ///@} ///@{ /** * The InstanceID of the EC2 instance that is hosting the compute.
*
A set of attributes for each container in the compute.
*/ inline const Aws::VectorThe game server container group definition for the compute.
*/ inline const Aws::String& GetGameServerContainerGroupDefinitionArn() const{ return m_gameServerContainerGroupDefinitionArn; } inline bool GameServerContainerGroupDefinitionArnHasBeenSet() const { return m_gameServerContainerGroupDefinitionArnHasBeenSet; } inline void SetGameServerContainerGroupDefinitionArn(const Aws::String& value) { m_gameServerContainerGroupDefinitionArnHasBeenSet = true; m_gameServerContainerGroupDefinitionArn = value; } inline void SetGameServerContainerGroupDefinitionArn(Aws::String&& value) { m_gameServerContainerGroupDefinitionArnHasBeenSet = true; m_gameServerContainerGroupDefinitionArn = std::move(value); } inline void SetGameServerContainerGroupDefinitionArn(const char* value) { m_gameServerContainerGroupDefinitionArnHasBeenSet = true; m_gameServerContainerGroupDefinitionArn.assign(value); } inline Compute& WithGameServerContainerGroupDefinitionArn(const Aws::String& value) { SetGameServerContainerGroupDefinitionArn(value); return *this;} inline Compute& WithGameServerContainerGroupDefinitionArn(Aws::String&& value) { SetGameServerContainerGroupDefinitionArn(std::move(value)); return *this;} inline Compute& WithGameServerContainerGroupDefinitionArn(const char* value) { SetGameServerContainerGroupDefinitionArn(value); return *this;} ///@} private: Aws::String m_fleetId; bool m_fleetIdHasBeenSet = false; Aws::String m_fleetArn; bool m_fleetArnHasBeenSet = false; Aws::String m_computeName; bool m_computeNameHasBeenSet = false; Aws::String m_computeArn; bool m_computeArnHasBeenSet = false; Aws::String m_ipAddress; bool m_ipAddressHasBeenSet = false; Aws::String m_dnsName; bool m_dnsNameHasBeenSet = false; ComputeStatus m_computeStatus; bool m_computeStatusHasBeenSet = false; Aws::String m_location; bool m_locationHasBeenSet = false; Aws::Utils::DateTime m_creationTime; bool m_creationTimeHasBeenSet = false; OperatingSystem m_operatingSystem; bool m_operatingSystemHasBeenSet = false; EC2InstanceType m_type; bool m_typeHasBeenSet = false; Aws::String m_gameLiftServiceSdkEndpoint; bool m_gameLiftServiceSdkEndpointHasBeenSet = false; Aws::String m_gameLiftAgentEndpoint; bool m_gameLiftAgentEndpointHasBeenSet = false; Aws::String m_instanceId; bool m_instanceIdHasBeenSet = false; Aws::Vector