WebsocketExtension

SoupWebsocketExtension is the base class for WebSocket extension objects.

Constructors

this
this(SoupWebsocketExtension* soupWebsocketExtension, bool ownedRef)

Sets our main struct and passes it to the parent class.

Members

Functions

configure
bool configure(SoupWebsocketConnectionType connectionType, HashTable params)

Configures @extension with the given @params

getRequestParams
string getRequestParams()

Get the parameters strings to be included in the request header. If the extension doesn't include any parameter in the request, this function returns %NULL.

getResponseParams
string getResponseParams()

Get the parameters strings to be included in the response header. If the extension doesn't include any parameter in the response, this function returns %NULL.

getStruct
void* getStruct()

the main Gtk struct as a void*

getWebsocketExtensionStruct
SoupWebsocketExtension* getWebsocketExtensionStruct(bool transferOwnership)

Get the main Gtk struct

processIncomingMessage
Bytes processIncomingMessage(ubyte header, Bytes payload)

Process a message after it's received. If the payload isn't changed the given @payload is just returned, otherwise g_bytes_unref() is called on the given @payload and a new #GBytes is returned with the new data.

processOutgoingMessage
Bytes processOutgoingMessage(ubyte header, Bytes payload)

Process a message before it's sent. If the payload isn't changed the given @payload is just returned, otherwise g_bytes_unref() is called on the given @payload and a new #GBytes is returned with the new data.

Static functions

getType
GType getType()

Variables

soupWebsocketExtension
SoupWebsocketExtension* soupWebsocketExtension;

the main Gtk struct

Meta

Since

2.68