Worker

Overview

Abstract base class for all synchronous workers which are used internally by the Server components to handle the individual connections. They are created by the Listener whenever a new connection comes in.

Location


 

constructor  protected

 

constructor(owner: Object)

 

Worker(Object owner)

 

Sub New(owner As Object)

Parameters:

  • owner:

DataConnection

Gets or sets the connection to the owner server listening socket.

 

property DataConnection: Connection read write;

 

Connection DataConnection { get; set; }

 

Property DataConnection() As Connection

Done

This event is fired after client connection being closed.

 

event Done: EventHandler;

 

delegate EventHandler Done()

 

Event Done As EventHandler

Owner

 

property Owner: Object read;

 

Object Owner { get; }

 

ReadOnly Property Owner() As Object

Thread

Gets or sets the thread to execute the Work method that is provided by IWorker interface.

 

property Thread: Thread read write;

 

Thread Thread { get; set; }

 

Property Thread() As Thread

Work

 

method Work

 

void Work()

 

Sub Work()

 

DataConnection

Gets or sets the connection to the owner server listening socket.

 

property DataConnection: Connection read write;

 

Connection DataConnection { get; set; }

 

Property DataConnection() As Connection

Owner

 

property Owner: Object read;

 

Object Owner { get; }

 

ReadOnly Property Owner() As Object

Thread

Gets or sets the thread to execute the Work method that is provided by IWorker interface.

 

property Thread: Thread read write;

 

Thread Thread { get; set; }

 

Property Thread() As Thread

 

constructor  protected

 

constructor(owner: Object)

 

Worker(Object owner)

 

Sub New(owner As Object)

Parameters:

  • owner:

Work

 

method Work

 

void Work()

 

Sub Work()

 

Done

This event is fired after client connection being closed.

 

event Done: EventHandler;

 

delegate EventHandler Done()

 

Event Done As EventHandler

 

 

  • Listener Class
  • Server Class