class Etf implements WSEncodingInterface (View source)

Handles WS encoding.

Properties

protected Kimberly $etf

Methods

__construct()

Constructor.

string
getName()

Returns encoding name (for gateway query string).

static void
supported()

Checks if the system supports it.

mixed
decode(string $data)

Decodes data.

string
encode(mixed $data)

Encodes data.

Message
prepareMessage(string $data)

Prepares the data to be sent.

array|object
convertIDs(array|object $data)

Converts all IDs from integer to strings.

Details

__construct()

Constructor.

string getName()

Returns encoding name (for gateway query string).

Return Value

string

static void supported()

Checks if the system supports it.

Return Value

void

Exceptions

RuntimeException

mixed decode(string $data)

Decodes data.

Parameters

string $data

Return Value

mixed

Exceptions

DiscordGatewayException

string encode(mixed $data)

Encodes data.

Parameters

mixed $data

Return Value

string

Exceptions

DiscordGatewayException

Message prepareMessage(string $data)

Prepares the data to be sent.

Parameters

string $data

Return Value

Message

protected array|object convertIDs(array|object $data)

Converts all IDs from integer to strings.

Parameters

array|object $data

Return Value

array|object