EGDL2 2.1
Loading...
Searching...
No Matches
WebSocketSharp Namespace Reference

Classes

class  CloseEventArgs
 Contains the event data associated with a WebSocket.OnClose event. More...
 
class  ErrorEventArgs
 Contains the event data associated with a WebSocket.OnError event. More...
 
class  Ext
 Provides a set of static methods for the websocket-sharp. More...
 
class  LogData
 Represents a log data used by the Logger class. More...
 
class  Logger
 Provides a set of methods and properties for logging. More...
 
class  MessageEventArgs
 Contains the event data associated with a WebSocket.OnMessage event. More...
 
class  WebSocket
 Implements the WebSocket interface. More...
 
class  WebSocketException
 The exception that is thrown when a WebSocket gets a fatal error. More...
 

Enumerations

enum  ByteOrder : byte { Little , Big }
 Contains the values that indicate whether the byte order is a Little-endian or Big-endian. More...
 
enum  CloseStatusCode : ushort {
  Normal = 1000 , Away = 1001 , ProtocolError = 1002 , IncorrectData = 1003 ,
  Undefined = 1004 , NoStatusCode = 1005 , Abnormal = 1006 , InconsistentData = 1007 ,
  PolicyViolation = 1008 , TooBig = 1009 , IgnoreExtension = 1010 , ServerError = 1011 ,
  TlsHandshakeFailure = 1015
}
 Contains the values of the status code for the WebSocket connection close. More...
 
enum  CompressionMethod : byte { None , Deflate }
 Contains the values of the compression method used to compress the message on the WebSocket connection. More...
 
enum  LogLevel {
  Trace , Debug , Info , Warn ,
  Error , Fatal
}
 Contains the values of the logging level. More...
 
enum  Opcode : byte {
  Cont = 0x0 , Text = 0x1 , Binary = 0x2 , Close = 0x8 ,
  Ping = 0x9 , Pong = 0xa
}
 Contains the values of the opcode that indicates the type of a WebSocket frame. More...
 
enum  WebSocketState : ushort { Connecting = 0 , Open = 1 , Closing = 2 , Closed = 3 }
 Contains the values of the state of the WebSocket connection. More...
 

Enumeration Type Documentation

◆ ByteOrder

Contains the values that indicate whether the byte order is a Little-endian or Big-endian.

Enumerator
Little 

Indicates a Little-endian.

Big 

Indicates a Big-endian.

◆ CloseStatusCode

Contains the values of the status code for the WebSocket connection close.

The values of the status code are defined in Section 7.4

of RFC 6455.

"Reserved value" must not be set as a status code in a close control frame by an endpoint. It's designated for use in applications expecting a status code to indicate that the connection was closed due to the system grounds.

Enumerator
Normal 

Equivalent to close status 1000. Indicates a normal close.

Away 

Equivalent to close status 1001. Indicates that an endpoint is going away.

ProtocolError 

Equivalent to close status 1002. Indicates that an endpoint is terminating the connection due to a protocol error.

IncorrectData 

Equivalent to close status 1003. Indicates that an endpoint is terminating the connection because it has received an unacceptable type message.

Undefined 

Equivalent to close status 1004. Still undefined. Reserved value.

NoStatusCode 

Equivalent to close status 1005. Indicates that no status code was actually present. Reserved value.

Abnormal 

Equivalent to close status 1006. Indicates that the connection was closed abnormally. Reserved value.

InconsistentData 

Equivalent to close status 1007. Indicates that an endpoint is terminating the connection because it has received a message that contains a data that isn't consistent with the type of the message.

PolicyViolation 

Equivalent to close status 1008. Indicates that an endpoint is terminating the connection because it has received a message that violates its policy.

TooBig 

Equivalent to close status 1009. Indicates that an endpoint is terminating the connection because it has received a message that is too big to process.

IgnoreExtension 

Equivalent to close status 1010. Indicates that the client is terminating the connection because it has expected the server to negotiate one or more extension, but the server didn't return them in the handshake response.

ServerError 

Equivalent to close status 1011. Indicates that the server is terminating the connection because it has encountered an unexpected condition that prevented it from fulfilling the request.

TlsHandshakeFailure 

Equivalent to close status 1015. Indicates that the connection was closed due to a failure to perform a TLS handshake. Reserved value.

◆ CompressionMethod

Contains the values of the compression method used to compress the message on the WebSocket connection.

The values of the compression method are defined in Compression Extensions for WebSocket

.

Enumerator
None 

Indicates non compression.

Deflate 

Indicates using DEFLATE.

◆ LogLevel

Contains the values of the logging level.

Enumerator
Trace 

Indicates the bottom logging level.

Debug 

Indicates the 2nd logging level from the bottom.

Info 

Indicates the 3rd logging level from the bottom.

Warn 

Indicates the 3rd logging level from the top.

Error 

Indicates the 2nd logging level from the top.

Fatal 

Indicates the top logging level.

◆ Opcode

enum WebSocketSharp.Opcode : byte

Contains the values of the opcode that indicates the type of a WebSocket frame.

The values of the opcode are defined in Section 5.2

of RFC 6455.

Enumerator
Cont 

Equivalent to numeric value 0. Indicates a continuation frame.

Text 

Equivalent to numeric value 1. Indicates a text frame.

Binary 

Equivalent to numeric value 2. Indicates a binary frame.

Close 

Equivalent to numeric value 8. Indicates a connection close frame.

Ping 

Equivalent to numeric value 9. Indicates a ping frame.

Pong 

Equivalent to numeric value 10. Indicates a pong frame.

◆ WebSocketState

Contains the values of the state of the WebSocket connection.

The values of the state are defined in The WebSocket API

.

Enumerator
Connecting 

Equivalent to numeric value 0. Indicates that the connection has not yet been established.

Open 

Equivalent to numeric value 1. Indicates that the connection is established and the communication is possible.

Closing 

Equivalent to numeric value 2. Indicates that the connection is going through the closing handshake or the WebSocket.Close method has been invoked.

Closed 

Equivalent to numeric value 3. Indicates that the connection has been closed or couldn't be opened.