websocket-sharp : WebSocketSharp.Server Namespace

IServiceHost Interface

Exposes the methods and property for the host that provides a WebSocketSharp.Server.WebSocketService.

Syntax

public interface IServiceHost

Remarks

Requirements

Namespace: WebSocketSharp.Server
Assembly: websocket-sharp (in websocket-sharp.dll)

Members

Public Properties

Sweeped bool . Gets or sets a value indicating whether the WebSocket service host cleans up the inactive service clients periodically.

Public Methods

BindWebSocket (WebSocketSharp.Net.WebSockets.WebSocketContext)
Binds the specified WebSocketSharp.Net.WebSockets.WebSocketContext to a WebSocketSharp.Server.WebSocketService instance.
Broadcast (string)
Broadcasts the specified string to all service clients.
Start ()
Starts the WebSocket service host.
Stop ()
Stops the WebSocket service host.

Extension Methods

static
IsNull<T> (this T) : bool
Determines whether the specified object is null.
static
IsNullDo<T> (this T, Action) : bool
Determines whether the specified object is null. And invokes the specified Action delegate if the specified object is null.

Member Details

BindWebSocket Method

Binds the specified WebSocketSharp.Net.WebSockets.WebSocketContext to a WebSocketSharp.Server.WebSocketService instance.

Syntax

Parameters

context
A WebSocketSharp.Net.WebSockets.WebSocketContext that contains the WebSocket connection request objects to bind.

Remarks

Documentation for this section has not yet been entered.

Requirements

Namespace: WebSocketSharp.Server
Assembly: websocket-sharp (in websocket-sharp.dll)

Broadcast Method

Broadcasts the specified string to all service clients.

Syntax

public void Broadcast (string data)

Parameters

data
A string to broadcast.

Remarks

Documentation for this section has not yet been entered.

Requirements

Namespace: WebSocketSharp.Server
Assembly: websocket-sharp (in websocket-sharp.dll)

Start Method

Starts the WebSocket service host.

Syntax

public void Start ()

Remarks

Documentation for this section has not yet been entered.

Requirements

Namespace: WebSocketSharp.Server
Assembly: websocket-sharp (in websocket-sharp.dll)

Stop Method

Stops the WebSocket service host.

Syntax

public void Stop ()

Remarks

Documentation for this section has not yet been entered.

Requirements

Namespace: WebSocketSharp.Server
Assembly: websocket-sharp (in websocket-sharp.dll)

Sweeped Property

Gets or sets a value indicating whether the WebSocket service host cleans up the inactive service clients periodically.

Syntax

public bool Sweeped { get; set; }

Value

true if the WebSocket service host cleans up the inactive service clients periodically; otherwise, false.

Remarks

Documentation for this section has not yet been entered.

Requirements

Namespace: WebSocketSharp.Server
Assembly: websocket-sharp (in websocket-sharp.dll)