OnDeviceRoundService class

An implementation of a RoundService for a local game on device with no server connection

Warning implementation not complete or tested yet

Inheritance

Constructors

OnDeviceRoundService()

Properties

hashCode int
The hash code for this object.
no setterinherited
logger → Logger
finalinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
sc StreamController<bool>
getter/setter pairinherited

Methods

connect() Stream<bool>
Connects to the backend
inherited
disconnect() Future<void>
Disconnect from the backend
inherited
dispose() → void
Disposes of the RoundService (i.e. disconnects from the server)
inherited
errorStream(PlayerID playerID, GameCode code) Stream<GameError>
override
exitGame(PlayerID playerID, GameCode code) Future<bool>
Causes the client to exit the game
override
gameLobby(PlayerID playerID, GameCode code) Stream<GameInfo>
override
gameStream(PlayerID playerID, GameCode code) Stream<GameState<Event, Game>>
override
newRound(PlayerID playerID, GameCode code) Future<bool>
Sends a new round event to the game server
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
sendEvent<E extends Event>(PlayerID playerID, GameCode code, E event) Future<bool>
Sends event to the game server
override
startGame(PlayerID playerID, GameCode code) Future<bool>
Sends a start request to the game server
override
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited