Class TerminateGameSessionRequest
- java.lang.Object
-
- software.amazon.awssdk.core.SdkRequest
-
- software.amazon.awssdk.awscore.AwsRequest
-
- software.amazon.awssdk.services.gamelift.model.GameLiftRequest
-
- software.amazon.awssdk.services.gamelift.model.TerminateGameSessionRequest
-
- All Implemented Interfaces:
SdkPojo,ToCopyableBuilder<TerminateGameSessionRequest.Builder,TerminateGameSessionRequest>
@Generated("software.amazon.awssdk:codegen") public final class TerminateGameSessionRequest extends GameLiftRequest implements ToCopyableBuilder<TerminateGameSessionRequest.Builder,TerminateGameSessionRequest>
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static interfaceTerminateGameSessionRequest.Builder
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static TerminateGameSessionRequest.Builderbuilder()booleanequals(Object obj)booleanequalsBySdkFields(Object obj)StringgameSessionId()A unique identifier for the game session to be terminated.<T> Optional<T>getValueForField(String fieldName, Class<T> clazz)inthashCode()Map<String,SdkField<?>>sdkFieldNameToField()List<SdkField<?>>sdkFields()static Class<? extends TerminateGameSessionRequest.Builder>serializableBuilderClass()TerminationModeterminationMode()The method to use to terminate the game session.StringterminationModeAsString()The method to use to terminate the game session.TerminateGameSessionRequest.BuildertoBuilder()StringtoString()Returns a string representation of this object.-
Methods inherited from class software.amazon.awssdk.awscore.AwsRequest
overrideConfiguration
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface software.amazon.awssdk.utils.builder.ToCopyableBuilder
copy
-
-
-
-
Method Detail
-
gameSessionId
public final String gameSessionId()
A unique identifier for the game session to be terminated. A game session ARN has the following format:
arn:aws:gamelift:<region>::gamesession/<fleet ID>/<custom ID string or idempotency token>.- Returns:
- A unique identifier for the game session to be terminated. A game session ARN has the following format:
arn:aws:gamelift:<region>::gamesession/<fleet ID>/<custom ID string or idempotency token>.
-
terminationMode
public final TerminationMode terminationMode()
The method to use to terminate the game session. Available methods include:
-
TRIGGER_ON_PROCESS_TERMINATE– Prompts the Amazon GameLift service to send anOnProcessTerminate()callback to the server process and initiate the normal game session shutdown sequence. TheOnProcessTerminatemethod, which is implemented in the game server code, must include a call to the server SDK actionProcessEnding(), which is how the server process signals to Amazon GameLift that a game session is ending. If the server process doesn't callProcessEnding(), the game session termination won't conclude successfully. -
FORCE_TERMINATE– Prompts the Amazon GameLift service to stop the server process immediately. Amazon GameLift takes action (depending on the type of fleet) to shut down the server process without the normal game session shutdown sequence.This method is not available for game sessions that are running on Anywhere fleets unless the fleet is deployed with the Amazon GameLift Agent. In this scenario, a force terminate request results in an invalid or bad request exception.
If the service returns an enum value that is not available in the current SDK version,
terminationModewill returnTerminationMode.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available fromterminationModeAsString().- Returns:
- The method to use to terminate the game session. Available methods include:
-
TRIGGER_ON_PROCESS_TERMINATE– Prompts the Amazon GameLift service to send anOnProcessTerminate()callback to the server process and initiate the normal game session shutdown sequence. TheOnProcessTerminatemethod, which is implemented in the game server code, must include a call to the server SDK actionProcessEnding(), which is how the server process signals to Amazon GameLift that a game session is ending. If the server process doesn't callProcessEnding(), the game session termination won't conclude successfully. -
FORCE_TERMINATE– Prompts the Amazon GameLift service to stop the server process immediately. Amazon GameLift takes action (depending on the type of fleet) to shut down the server process without the normal game session shutdown sequence.This method is not available for game sessions that are running on Anywhere fleets unless the fleet is deployed with the Amazon GameLift Agent. In this scenario, a force terminate request results in an invalid or bad request exception.
-
- See Also:
TerminationMode
-
-
terminationModeAsString
public final String terminationModeAsString()
The method to use to terminate the game session. Available methods include:
-
TRIGGER_ON_PROCESS_TERMINATE– Prompts the Amazon GameLift service to send anOnProcessTerminate()callback to the server process and initiate the normal game session shutdown sequence. TheOnProcessTerminatemethod, which is implemented in the game server code, must include a call to the server SDK actionProcessEnding(), which is how the server process signals to Amazon GameLift that a game session is ending. If the server process doesn't callProcessEnding(), the game session termination won't conclude successfully. -
FORCE_TERMINATE– Prompts the Amazon GameLift service to stop the server process immediately. Amazon GameLift takes action (depending on the type of fleet) to shut down the server process without the normal game session shutdown sequence.This method is not available for game sessions that are running on Anywhere fleets unless the fleet is deployed with the Amazon GameLift Agent. In this scenario, a force terminate request results in an invalid or bad request exception.
If the service returns an enum value that is not available in the current SDK version,
terminationModewill returnTerminationMode.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available fromterminationModeAsString().- Returns:
- The method to use to terminate the game session. Available methods include:
-
TRIGGER_ON_PROCESS_TERMINATE– Prompts the Amazon GameLift service to send anOnProcessTerminate()callback to the server process and initiate the normal game session shutdown sequence. TheOnProcessTerminatemethod, which is implemented in the game server code, must include a call to the server SDK actionProcessEnding(), which is how the server process signals to Amazon GameLift that a game session is ending. If the server process doesn't callProcessEnding(), the game session termination won't conclude successfully. -
FORCE_TERMINATE– Prompts the Amazon GameLift service to stop the server process immediately. Amazon GameLift takes action (depending on the type of fleet) to shut down the server process without the normal game session shutdown sequence.This method is not available for game sessions that are running on Anywhere fleets unless the fleet is deployed with the Amazon GameLift Agent. In this scenario, a force terminate request results in an invalid or bad request exception.
-
- See Also:
TerminationMode
-
-
toBuilder
public TerminateGameSessionRequest.Builder toBuilder()
- Specified by:
toBuilderin interfaceToCopyableBuilder<TerminateGameSessionRequest.Builder,TerminateGameSessionRequest>- Specified by:
toBuilderin classGameLiftRequest
-
builder
public static TerminateGameSessionRequest.Builder builder()
-
serializableBuilderClass
public static Class<? extends TerminateGameSessionRequest.Builder> serializableBuilderClass()
-
hashCode
public final int hashCode()
- Overrides:
hashCodein classAwsRequest
-
equals
public final boolean equals(Object obj)
- Overrides:
equalsin classAwsRequest
-
equalsBySdkFields
public final boolean equalsBySdkFields(Object obj)
- Specified by:
equalsBySdkFieldsin interfaceSdkPojo
-
toString
public final String toString()
Returns a string representation of this object. This is useful for testing and debugging. Sensitive data will be redacted from this string using a placeholder value.
-
getValueForField
public final <T> Optional<T> getValueForField(String fieldName, Class<T> clazz)
- Overrides:
getValueForFieldin classSdkRequest
-
sdkFieldNameToField
public final Map<String,SdkField<?>> sdkFieldNameToField()
- Specified by:
sdkFieldNameToFieldin interfaceSdkPojo
-
-