C# Class WebSocketSharp.Net.HttpListener

Inheritance: IDisposable
Afficher le fichier Open project: NIAEFEUP/Kommando Class Usage Examples

Méthodes publiques

Méthode Description
Abort ( ) : void

Shuts down the HttpListener immediately.

BeginGetContext ( AsyncCallback callback, Object state ) : IAsyncResult

Begins getting an incoming request information asynchronously.

This asynchronous operation must be completed by calling the EndGetContext method. Typically, the method is invoked by the callback delegate.

Close ( ) : void

Shuts down the HttpListener.

EndGetContext ( IAsyncResult asyncResult ) : HttpListenerContext

Ends an asynchronous operation to get an incoming request information.

This method completes an asynchronous operation started by calling the BeginGetContext method.

GetContext ( ) : HttpListenerContext

Gets an incoming request information.

This method waits for an incoming request and returns the request information when received the request.

HttpListener ( ) : System

Initializes a new instance of the HttpListener class.

Start ( ) : void

Starts to receive incoming requests.

Stop ( ) : void

Stops receiving incoming requests.

Private Methods

Méthode Description
AddConnection ( HttpConnection cnc ) : void
CheckDisposed ( ) : void
Cleanup ( bool force ) : void
CleanupConnections ( ) : void
CleanupContextRegistry ( ) : void
CleanupWaitQueue ( ) : void
Close ( bool force ) : void
GetContextFromQueue ( ) : HttpListenerContext
IDisposable ( ) : void

Releases all resource used by the HttpListener.

RegisterContext ( HttpListenerContext context ) : void
RemoveConnection ( HttpConnection cnc ) : void
SelectAuthenticationScheme ( HttpListenerContext context ) : AuthenticationSchemes
SendServiceUnavailable ( ) : void
UnregisterContext ( HttpListenerContext context ) : void

Method Details

Abort() public méthode

Shuts down the HttpListener immediately.
public Abort ( ) : void
Résultat void

BeginGetContext() public méthode

Begins getting an incoming request information asynchronously.
This asynchronous operation must be completed by calling the EndGetContext method. Typically, the method is invoked by the callback delegate.
/// This object has been closed. /// /// The has not been started or is stopped currently. ///
public BeginGetContext ( AsyncCallback callback, Object state ) : IAsyncResult
callback AsyncCallback /// An delegate that references the method(s) /// called when the asynchronous operation completes. ///
state Object /// An that contains a user defined object to pass to the delegate. ///
Résultat IAsyncResult

Close() public méthode

Shuts down the HttpListener.
public Close ( ) : void
Résultat void

EndGetContext() public méthode

Ends an asynchronous operation to get an incoming request information.
This method completes an asynchronous operation started by calling the BeginGetContext method.
/// This object has been closed. /// /// is . /// /// was not obtained by calling the method. /// /// The EndGetContext method was already called for the specified . ///
public EndGetContext ( IAsyncResult asyncResult ) : HttpListenerContext
asyncResult IAsyncResult /// An obtained by calling the method. ///
Résultat HttpListenerContext

GetContext() public méthode

Gets an incoming request information.
This method waits for an incoming request and returns the request information when received the request.
/// /// The does not have any URI prefixes to listen on. /// /// /// -or- /// /// /// The has not been started or is stopped currently. /// /// /// This object has been closed. ///
public GetContext ( ) : HttpListenerContext
Résultat HttpListenerContext

HttpListener() public méthode

Initializes a new instance of the HttpListener class.
public HttpListener ( ) : System
Résultat System

Start() public méthode

Starts to receive incoming requests.
/// This object has been closed. ///
public Start ( ) : void
Résultat void

Stop() public méthode

Stops receiving incoming requests.
/// This object has been closed. ///
public Stop ( ) : void
Résultat void