Documentation

NetworkSessionManager
in package

Table of Contents

$sessions  : array<string|int, NetworkSession>
add()  : void
Adds a network session to the manager. This should only be called on session creation.
close()  : void
Terminates all connected sessions with the given reason.
getSessionCount()  : int
Returns the number of known connected sessions.
getSessions()  : array<string|int, NetworkSession>
remove()  : void
Removes the given network session, due to disconnect. This should only be called by a network session on disconnection.
tick()  : void
Updates all sessions which need it.

Properties

Methods

close()

Terminates all connected sessions with the given reason.

public close([string $reason = "" ]) : void
Parameters
$reason : string = ""
Return values
void

getSessionCount()

Returns the number of known connected sessions.

public getSessionCount() : int
Return values
int

remove()

Removes the given network session, due to disconnect. This should only be called by a network session on disconnection.

public remove(NetworkSession $session) : void
Parameters
$session : NetworkSession
Return values
void

Search results