gpg:: RealTimeRoom
#include <real_time_room.h>
A data structure containing the current state of a real-time multiplayer room.
Summary
Constructors and Destructors |
|
---|---|
RealTimeRoom()
|
|
RealTimeRoom(std::shared_ptr< const RealTimeRoomImpl > impl)
|
|
RealTimeRoom(const RealTimeRoom & copy_from)
Creates a copy of an existing
RealTimeRoom object. |
|
RealTimeRoom(RealTimeRoom && move_from)
Moves an existing
RealTimeRoom object. |
Public functions |
|
---|---|
AutomatchWaitEstimate() const
|
A server-generated estimate of the amount of time it will take to fill this room's auto-matching slots.
|
CreatingParticipant() const
|
Returns the participant who created this room.
|
CreationTime() const
|
std::chrono::milliseconds
Returns the time at which this
RealTimeRoom object was created (expressed as milliseconds since the Unix epoch). |
Description() const
|
std::string
Returns a server-generated summary of the state of the room.
|
Id() const
|
const std::string &
Returns an ID that uniquely identifies this
RealTimeRoom object. |
Participants() const
|
std::vector< MultiplayerParticipant >
A vector of all participants in this room.
|
RemainingAutomatchingSlots() const
|
uint32_t
Returns the number of available auto-matching slots for the room.
|
Status() const
|
Returns the status of the room.
|
Valid() const
|
bool
Returns true if this
RealTimeRoom object is populated with data. |
Variant() const
|
uint32_t
Returns a game-specific variant identifier that can be used by a game to identify different game modes.
|
operator=(const RealTimeRoom & copy_from)
|
Assigns this
RealTimeRoom object by copying from another one. |
operator=(RealTimeRoom && move_from)
|
Assigns this
RealTimeRoom object by moving another one into it. |
Public functions
AutomatchWaitEstimate
Timeout AutomatchWaitEstimate() const
A server-generated estimate of the amount of time it will take to fill this room's auto-matching slots.
CreatingParticipant
MultiplayerParticipant CreatingParticipant() const
Returns the participant who created this room.
Valid must return true for this function to be usable.
CreationTime
std::chrono::milliseconds CreationTime() const
Returns the time at which this RealTimeRoom
object was created (expressed as milliseconds since the Unix epoch).
Valid must return true for this function to be usable.
Description
std::string Description() const
Returns a server-generated summary of the state of the room.
Valid must return true for this function to be usable.
Id
const std::string & Id() const
Returns an ID that uniquely identifies this RealTimeRoom
object.
To retrieve this room at a later point, use this ID with RealTimeRoom::FetchRoom
.
Valid must return true for this function to be usable.
Participants
std::vector< MultiplayerParticipant > Participants() const
A vector of all participants in this room.
Valid must return true for this function to be usable.
RealTimeRoom
RealTimeRoom()
RealTimeRoom
RealTimeRoom( std::shared_ptr< const RealTimeRoomImpl > impl )
Constructs a RealTimeRoom
object from a shared_ptr
to a RealTimeRoomImpl
object.
Intended for internal use by the API.
RealTimeRoom
RealTimeRoom( const RealTimeRoom & copy_from )
Creates a copy of an existing RealTimeRoom
object.
RemainingAutomatchingSlots
uint32_t RemainingAutomatchingSlots() const
Returns the number of available auto-matching slots for the room.
This number is equal to the number of auto-matching slots with which the room was created, minus the number of participants who have already been added via auto-matching. Valid must return true for this function to be usable.
Status
RealTimeRoomStatus Status() const
Returns the status of the room.
The status determines what actions can be taken on a room. Valid must return true for this function to be usable.
Valid
bool Valid() const
Returns true if this RealTimeRoom
object is populated with data.
Must return true for the getter functions on the RealTimeRoom
object (Id
, CreationTime
, etc...) to be usable.
Variant
uint32_t Variant() const
Returns a game-specific variant identifier that can be used by a game to identify different game modes.
Valid must return true for this function to be usable.
operator=
RealTimeRoom & operator=( const RealTimeRoom & copy_from )
Assigns this RealTimeRoom
object by copying from another one.
operator=
RealTimeRoom & operator=( RealTimeRoom && move_from )
Assigns this RealTimeRoom
object by moving another one into it.