cocos2d-x  3.1rc0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
SocketIO Class Reference

Singleton and wrapper class to provide static creation method as well as registry of all sockets. More...

#include <SocketIO.h>

Classes

class  SIODelegate
 The delegate class to process socket.io events. More...
 

Static Public Member Functions

static SocketIOgetInstance ()
static void destroyInstance ()
var destroyInstance ()
local destroyInstance ()
static SIOClientconnect (const std::string &uri, SocketIO::SIODelegate &delegate)
 Static client creation method, similar to socketio.connect(uri) in JS. More...
 
static CC_DEPRECATED_ATTRIBUTE
SIOClient
connect (SocketIO::SIODelegate &delegate, const std::string &uri)

Friends

class SIOClientImpl

Detailed Description

Singleton and wrapper class to provide static creation method as well as registry of all sockets.

Member Function Documentation

static SIOClient* connect ( const std::string &  uri,
SocketIO::SIODelegate delegate 
)
static

Static client creation method, similar to socketio.connect(uri) in JS.

Parameters
delegateThe delegate which want to receive events from the socket.io client
uriThe URI of the socket.io server
Returns
An initialized SIOClient if connected successfully, otherwise NULL
static CC_DEPRECATED_ATTRIBUTE
SIOClient* connect
( SocketIO::SIODelegate delegate,
const std::string &  uri 
)
static
var connect ( var  delegate,
var  uri 
)
static
local connect ( local  delegate,
local  uri 
)
static
static void destroyInstance ( )
static
var destroyInstance ( )
static
local destroyInstance ( )
static
static SocketIO* getInstance ( )
static
var getInstance ( )
static
local getInstance ( )
static

Friends And Related Function Documentation

friend class SIOClientImpl
friend
var SIOClientImpl
friend
local SIOClientImpl
friend

The documentation for this class was generated from the following file: