/* * Copyright 2018-2023 Amazon.com, Inc. or its affiliates. All Rights Reserved. * * Licensed under the Apache License, Version 2.0 (the "License"). You may not use this file except in compliance with * the License. A copy of the License is located at * * http://aws.amazon.com/apache2.0 * * or in the "license" file accompanying this file. This file is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR * CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions * and limitations under the License. */ package com.amazonaws.services.gamelift.model; import java.io.Serializable; import javax.annotation.Generated; import com.amazonaws.protocol.StructuredPojo; import com.amazonaws.protocol.ProtocolMarshaller; /** *
* Represents a player in matchmaking. When starting a matchmaking request, a player has a player ID, attributes, and * may have latency data. Team information is added after a match has been successfully completed. *
* * @see AWS API * Documentation */ @Generated("com.amazonaws:aws-java-sdk-code-generator") public class Player implements Serializable, Cloneable, StructuredPojo { /** ** A unique identifier for a player *
*/ private String playerId; /** *
* A collection of key:value pairs containing player information for use in matchmaking. Player attribute keys must
* match the playerAttributes used in a matchmaking rule set. Example:
* "PlayerAttributes": {"skill": {"N": "23"}, "gameMode": {"S": "deathmatch"}}
.
*
* You can provide up to 10 PlayerAttributes
.
*
* Name of the team that the player is assigned to in a match. Team names are defined in a matchmaking rule set. *
*/ private String team; /** ** A set of values, expressed in milliseconds, that indicates the amount of latency that a player experiences when * connected to @aws; Regions. If this property is present, FlexMatch considers placing the match only in Regions * for which latency is reported. *
** If a matchmaker has a rule that evaluates player latency, players must report latency in order to be matched. If * no latency is reported in this scenario, FlexMatch assumes that no Regions are available to the player and the * ticket is not matchable. *
*/ private java.util.Map* A unique identifier for a player *
* * @param playerId * A unique identifier for a player */ public void setPlayerId(String playerId) { this.playerId = playerId; } /** ** A unique identifier for a player *
* * @return A unique identifier for a player */ public String getPlayerId() { return this.playerId; } /** ** A unique identifier for a player *
* * @param playerId * A unique identifier for a player * @return Returns a reference to this object so that method calls can be chained together. */ public Player withPlayerId(String playerId) { setPlayerId(playerId); return this; } /** *
* A collection of key:value pairs containing player information for use in matchmaking. Player attribute keys must
* match the playerAttributes used in a matchmaking rule set. Example:
* "PlayerAttributes": {"skill": {"N": "23"}, "gameMode": {"S": "deathmatch"}}
.
*
* You can provide up to 10 PlayerAttributes
.
*
"PlayerAttributes": {"skill": {"N": "23"}, "gameMode": {"S": "deathmatch"}}
.
*
* You can provide up to 10
* A collection of key:value pairs containing player information for use in matchmaking. Player attribute keys must
* match the playerAttributes used in a matchmaking rule set. Example:
*
* You can provide up to 10 PlayerAttributes
.
*/
public java.util.Map"PlayerAttributes": {"skill": {"N": "23"}, "gameMode": {"S": "deathmatch"}}
.
* PlayerAttributes
.
* "PlayerAttributes": {"skill": {"N": "23"}, "gameMode": {"S": "deathmatch"}}
.
* You can provide up to 10
* A collection of key:value pairs containing player information for use in matchmaking. Player attribute keys must
* match the playerAttributes used in a matchmaking rule set. Example:
*
* You can provide up to 10 PlayerAttributes
.
*/
public void setPlayerAttributes(java.util.Map"PlayerAttributes": {"skill": {"N": "23"}, "gameMode": {"S": "deathmatch"}}
.
* PlayerAttributes
.
* "PlayerAttributes": {"skill": {"N": "23"}, "gameMode": {"S": "deathmatch"}}
.
* You can provide up to 10
* Name of the team that the player is assigned to in a match. Team names are defined in a matchmaking rule set.
*
* Name of the team that the player is assigned to in a match. Team names are defined in a matchmaking rule set.
*
* Name of the team that the player is assigned to in a match. Team names are defined in a matchmaking rule set.
*
* A set of values, expressed in milliseconds, that indicates the amount of latency that a player experiences when
* connected to @aws; Regions. If this property is present, FlexMatch considers placing the match only in Regions
* for which latency is reported.
*
* If a matchmaker has a rule that evaluates player latency, players must report latency in order to be matched. If
* no latency is reported in this scenario, FlexMatch assumes that no Regions are available to the player and the
* ticket is not matchable.
* PlayerAttributes
.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public Player withPlayerAttributes(java.util.Map
* If a matchmaker has a rule that evaluates player latency, players must report latency in order to be
* matched. If no latency is reported in this scenario, FlexMatch assumes that no Regions are available to
* the player and the ticket is not matchable.
*/
public java.util.Map
* A set of values, expressed in milliseconds, that indicates the amount of latency that a player experiences when
* connected to @aws; Regions. If this property is present, FlexMatch considers placing the match only in Regions
* for which latency is reported.
*
* If a matchmaker has a rule that evaluates player latency, players must report latency in order to be matched. If
* no latency is reported in this scenario, FlexMatch assumes that no Regions are available to the player and the
* ticket is not matchable.
*
* If a matchmaker has a rule that evaluates player latency, players must report latency in order to be
* matched. If no latency is reported in this scenario, FlexMatch assumes that no Regions are available to
* the player and the ticket is not matchable.
*/
public void setLatencyInMs(java.util.Map
* A set of values, expressed in milliseconds, that indicates the amount of latency that a player experiences when
* connected to @aws; Regions. If this property is present, FlexMatch considers placing the match only in Regions
* for which latency is reported.
*
* If a matchmaker has a rule that evaluates player latency, players must report latency in order to be matched. If
* no latency is reported in this scenario, FlexMatch assumes that no Regions are available to the player and the
* ticket is not matchable.
*
* If a matchmaker has a rule that evaluates player latency, players must report latency in order to be
* matched. If no latency is reported in this scenario, FlexMatch assumes that no Regions are available to
* the player and the ticket is not matchable.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public Player withLatencyInMs(java.util.Map