C# Class m.Http.Backend.Tcp.WebSocketSession

Inheritance: TcpSessionBase, IWebSocketSession
Afficher le fichier Open project: joongonn/mHttp Class Usage Examples

Méthodes publiques

Méthode Description
CloseSession ( ushort statusCode, string reason = null ) : void
Dispose ( ) : void
ReadNextMessageAsync ( ) : Task
SendBinary ( byte blob ) : void
SendClose ( ushort statusCode, string reason = null ) : void
SendPing ( ) : void
SendPong ( ) : void
SendText ( string text ) : void
WebSocketSession ( long id, TcpClient tcpClient, Stream stream, Action onBytesReceived, Action onBytesSent, System.Action onDisposed, int initialReadBufferSize, int readTimeoutMs, int writeTimeoutMs ) : System

Private Methods

Méthode Description
TryDecodeNextMessage ( OpCode &opCode, byte &messagePayload ) : bool
Write ( OpCode opCode, byte payload = null ) : void

Method Details

CloseSession() public méthode

public CloseSession ( ushort statusCode, string reason = null ) : void
statusCode ushort
reason string
Résultat void

Dispose() public méthode

public Dispose ( ) : void
Résultat void

ReadNextMessageAsync() public méthode

public ReadNextMessageAsync ( ) : Task
Résultat Task

SendBinary() public méthode

public SendBinary ( byte blob ) : void
blob byte
Résultat void

SendClose() public méthode

public SendClose ( ushort statusCode, string reason = null ) : void
statusCode ushort
reason string
Résultat void

SendPing() public méthode

public SendPing ( ) : void
Résultat void

SendPong() public méthode

public SendPong ( ) : void
Résultat void

SendText() public méthode

public SendText ( string text ) : void
text string
Résultat void

WebSocketSession() public méthode

public WebSocketSession ( long id, TcpClient tcpClient, Stream stream, Action onBytesReceived, Action onBytesSent, System.Action onDisposed, int initialReadBufferSize, int readTimeoutMs, int writeTimeoutMs ) : System
id long
tcpClient System.Net.Sockets.TcpClient
stream Stream
onBytesReceived Action
onBytesSent Action
onDisposed System.Action
initialReadBufferSize int
readTimeoutMs int
writeTimeoutMs int
Résultat System