MobiledgeX.MobiledgeXWebSocketClient Class Reference
Inheritance diagram for MobiledgeX.MobiledgeXWebSocketClient:

Public Member Functions

bool isConnecting ()
 
bool isOpen ()
 
async Task Connect (Uri uri)
 
void Send (string message)
 For Sending Text Messages to the server (ex. JSON) More...
 
void Send (byte[] binary)
 For Sending Binary to the server More...
 
async void RunSend ()
 RunSend is used in sendThread
 
async void RunSendBinary ()
 RunSendBinary is used in sendThreadBinary
 
async Task< Dictionary< WebSocketMessageType, MemoryStream > > Receive (ulong maxSize=MAXREADSIZE)
 
async void RunReceive ()
 RunReceive is used in receive thread RunReceive receives websocket messages asynchronously and add it to either receiveQueue or receiveQueueBinary ... dependent on the MessageType
 
void Dispose ()
 

Properties

ConcurrentQueue< string > receiveQueue [get]
 
ConcurrentQueue< byte[]> receiveQueueBinary [get]
 
BlockingCollection< ArraySegment< byte > > sendQueue [get]
 
BlockingCollection< ArraySegment< byte > > sendQueueBinary [get]
 
CancellationTokenSource tokenSource [getset]
 

Member Function Documentation

◆ Send() [1/2]

void MobiledgeX.MobiledgeXWebSocketClient.Send ( byte[]  binary)
inline

For Sending Binary to the server

Parameters
binary

◆ Send() [2/2]

void MobiledgeX.MobiledgeXWebSocketClient.Send ( string  message)
inline

For Sending Text Messages to the server (ex. JSON)

Parameters
message

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