Interface MatchmakingTicket.Builder

All Superinterfaces:
Buildable, CopyableBuilder<MatchmakingTicket.Builder,MatchmakingTicket>, SdkBuilder<MatchmakingTicket.Builder,MatchmakingTicket>, SdkPojo
Enclosing class:
MatchmakingTicket

public static interface MatchmakingTicket.Builder extends SdkPojo, CopyableBuilder<MatchmakingTicket.Builder,MatchmakingTicket>
  • Method Details

    • ticketId

      MatchmakingTicket.Builder ticketId(String ticketId)

      A unique identifier for a matchmaking ticket.

      Parameters:
      ticketId - A unique identifier for a matchmaking ticket.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • configurationName

      MatchmakingTicket.Builder configurationName(String configurationName)

      Name of the matchmaking configuration that is used with this ticket. Matchmaking configurations determine how players are grouped into a match and how a new game session is created for the match.

      Parameters:
      configurationName - Name of the matchmaking configuration that is used with this ticket. Matchmaking configurations determine how players are grouped into a match and how a new game session is created for the match.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • configurationArn

      MatchmakingTicket.Builder configurationArn(String configurationArn)

      The Amazon Resource Name (ARN) associated with the GameLift matchmaking configuration resource that is used with this ticket.

      Parameters:
      configurationArn - The Amazon Resource Name (ARN) associated with the GameLift matchmaking configuration resource that is used with this ticket.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • status

      Current status of the matchmaking request.

      • QUEUED -- The matchmaking request has been received and is currently waiting to be processed.

      • SEARCHING -- The matchmaking request is currently being processed.

      • REQUIRES_ACCEPTANCE -- A match has been proposed and the players must accept the match. This status is used only with requests that use a matchmaking configuration with a player acceptance requirement.

      • PLACING -- The FlexMatch engine has matched players and is in the process of placing a new game session for the match.

      • COMPLETED -- Players have been matched and a game session is ready to host the players. A ticket in this state contains the necessary connection information for players.

      • FAILED -- The matchmaking request was not completed.

      • CANCELLED -- The matchmaking request was canceled. This may be the result of a StopMatchmaking operation or a proposed match that one or more players failed to accept.

      • TIMED_OUT -- The matchmaking request was not successful within the duration specified in the matchmaking configuration.

      Matchmaking requests that fail to successfully complete (statuses FAILED, CANCELLED, TIMED_OUT) can be resubmitted as new requests with new ticket IDs.

      Parameters:
      status - Current status of the matchmaking request.

      • QUEUED -- The matchmaking request has been received and is currently waiting to be processed.

      • SEARCHING -- The matchmaking request is currently being processed.

      • REQUIRES_ACCEPTANCE -- A match has been proposed and the players must accept the match. This status is used only with requests that use a matchmaking configuration with a player acceptance requirement.

      • PLACING -- The FlexMatch engine has matched players and is in the process of placing a new game session for the match.

      • COMPLETED -- Players have been matched and a game session is ready to host the players. A ticket in this state contains the necessary connection information for players.

      • FAILED -- The matchmaking request was not completed.

      • CANCELLED -- The matchmaking request was canceled. This may be the result of a StopMatchmaking operation or a proposed match that one or more players failed to accept.

      • TIMED_OUT -- The matchmaking request was not successful within the duration specified in the matchmaking configuration.

      Matchmaking requests that fail to successfully complete (statuses FAILED, CANCELLED, TIMED_OUT) can be resubmitted as new requests with new ticket IDs.

      Returns:
      Returns a reference to this object so that method calls can be chained together.
      See Also:
    • status

      Current status of the matchmaking request.

      • QUEUED -- The matchmaking request has been received and is currently waiting to be processed.

      • SEARCHING -- The matchmaking request is currently being processed.

      • REQUIRES_ACCEPTANCE -- A match has been proposed and the players must accept the match. This status is used only with requests that use a matchmaking configuration with a player acceptance requirement.

      • PLACING -- The FlexMatch engine has matched players and is in the process of placing a new game session for the match.

      • COMPLETED -- Players have been matched and a game session is ready to host the players. A ticket in this state contains the necessary connection information for players.

      • FAILED -- The matchmaking request was not completed.

      • CANCELLED -- The matchmaking request was canceled. This may be the result of a StopMatchmaking operation or a proposed match that one or more players failed to accept.

      • TIMED_OUT -- The matchmaking request was not successful within the duration specified in the matchmaking configuration.

      Matchmaking requests that fail to successfully complete (statuses FAILED, CANCELLED, TIMED_OUT) can be resubmitted as new requests with new ticket IDs.

      Parameters:
      status - Current status of the matchmaking request.

      • QUEUED -- The matchmaking request has been received and is currently waiting to be processed.

      • SEARCHING -- The matchmaking request is currently being processed.

      • REQUIRES_ACCEPTANCE -- A match has been proposed and the players must accept the match. This status is used only with requests that use a matchmaking configuration with a player acceptance requirement.

      • PLACING -- The FlexMatch engine has matched players and is in the process of placing a new game session for the match.

      • COMPLETED -- Players have been matched and a game session is ready to host the players. A ticket in this state contains the necessary connection information for players.

      • FAILED -- The matchmaking request was not completed.

      • CANCELLED -- The matchmaking request was canceled. This may be the result of a StopMatchmaking operation or a proposed match that one or more players failed to accept.

      • TIMED_OUT -- The matchmaking request was not successful within the duration specified in the matchmaking configuration.

      Matchmaking requests that fail to successfully complete (statuses FAILED, CANCELLED, TIMED_OUT) can be resubmitted as new requests with new ticket IDs.

      Returns:
      Returns a reference to this object so that method calls can be chained together.
      See Also:
    • statusReason

      MatchmakingTicket.Builder statusReason(String statusReason)

      Code to explain the current status. For example, a status reason may indicate when a ticket has returned to SEARCHING status after a proposed match fails to receive player acceptances.

      Parameters:
      statusReason - Code to explain the current status. For example, a status reason may indicate when a ticket has returned to SEARCHING status after a proposed match fails to receive player acceptances.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • statusMessage

      MatchmakingTicket.Builder statusMessage(String statusMessage)

      Additional information about the current status.

      Parameters:
      statusMessage - Additional information about the current status.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • startTime

      MatchmakingTicket.Builder startTime(Instant startTime)

      Time stamp indicating when this matchmaking request was received. Format is a number expressed in Unix time as milliseconds (for example "1469498468.057").

      Parameters:
      startTime - Time stamp indicating when this matchmaking request was received. Format is a number expressed in Unix time as milliseconds (for example "1469498468.057").
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • endTime

      Time stamp indicating when the matchmaking request stopped being processed due to successful completion, timeout, or cancellation. Format is a number expressed in Unix time as milliseconds (for example "1469498468.057").

      Parameters:
      endTime - Time stamp indicating when the matchmaking request stopped being processed due to successful completion, timeout, or cancellation. Format is a number expressed in Unix time as milliseconds (for example "1469498468.057").
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • players

      A set of Player objects, each representing a player to find matches for. Players are identified by a unique player ID and may include latency data for use during matchmaking. If the ticket is in status COMPLETED, the Player objects include the team the players were assigned to in the resulting match.

      Parameters:
      players - A set of Player objects, each representing a player to find matches for. Players are identified by a unique player ID and may include latency data for use during matchmaking. If the ticket is in status COMPLETED, the Player objects include the team the players were assigned to in the resulting match.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • players

      MatchmakingTicket.Builder players(Player... players)

      A set of Player objects, each representing a player to find matches for. Players are identified by a unique player ID and may include latency data for use during matchmaking. If the ticket is in status COMPLETED, the Player objects include the team the players were assigned to in the resulting match.

      Parameters:
      players - A set of Player objects, each representing a player to find matches for. Players are identified by a unique player ID and may include latency data for use during matchmaking. If the ticket is in status COMPLETED, the Player objects include the team the players were assigned to in the resulting match.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • players

      A set of Player objects, each representing a player to find matches for. Players are identified by a unique player ID and may include latency data for use during matchmaking. If the ticket is in status COMPLETED, the Player objects include the team the players were assigned to in the resulting match.

      This is a convenience method that creates an instance of the Player.Builder avoiding the need to create one manually via Player.builder().

      When the Consumer completes, SdkBuilder.build() is called immediately and its result is passed to players(List<Player>).

      Parameters:
      players - a consumer that will call methods on Player.Builder
      Returns:
      Returns a reference to this object so that method calls can be chained together.
      See Also:
    • gameSessionConnectionInfo

      MatchmakingTicket.Builder gameSessionConnectionInfo(GameSessionConnectionInfo gameSessionConnectionInfo)

      Connection information for a new game session. Once a match is made, the FlexMatch engine creates a new game session for it. This information is added to the matchmaking ticket, which you can be retrieve by calling DescribeMatchmaking .

      Parameters:
      gameSessionConnectionInfo - Connection information for a new game session. Once a match is made, the FlexMatch engine creates a new game session for it. This information is added to the matchmaking ticket, which you can be retrieve by calling DescribeMatchmaking .
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • gameSessionConnectionInfo

      default MatchmakingTicket.Builder gameSessionConnectionInfo(Consumer<GameSessionConnectionInfo.Builder> gameSessionConnectionInfo)

      Connection information for a new game session. Once a match is made, the FlexMatch engine creates a new game session for it. This information is added to the matchmaking ticket, which you can be retrieve by calling DescribeMatchmaking .

      This is a convenience method that creates an instance of the GameSessionConnectionInfo.Builder avoiding the need to create one manually via GameSessionConnectionInfo.builder().

      When the Consumer completes, SdkBuilder.build() is called immediately and its result is passed to gameSessionConnectionInfo(GameSessionConnectionInfo).

      Parameters:
      gameSessionConnectionInfo - a consumer that will call methods on GameSessionConnectionInfo.Builder
      Returns:
      Returns a reference to this object so that method calls can be chained together.
      See Also:
    • estimatedWaitTime

      MatchmakingTicket.Builder estimatedWaitTime(Integer estimatedWaitTime)

      Average amount of time (in seconds) that players are currently waiting for a match. If there is not enough recent data, this property may be empty.

      Parameters:
      estimatedWaitTime - Average amount of time (in seconds) that players are currently waiting for a match. If there is not enough recent data, this property may be empty.
      Returns:
      Returns a reference to this object so that method calls can be chained together.