TROLocalServer Class

From RemObjects Wiki
Jump to: navigation, search

This is a Library topic for RemObjects SDK for Delphi
This page is generated from external data, please do not update

InterfacesClassesAliasesImplements

Contents

Overview

TROLocalServer implements a server that makes services available for consumption from within the same executable via a TROLocalChannel.

This channel is helpful when creating a single-tier version of an existing client/server application, and you want to combine client and server logic in the same executable and avoid the overhead of a "real" communication channel between client and server.


Location

uROLocalServer.pas

Implemented interfaces


Properties

Active

Toggles whether the server is ready to receive requests from clients. Depending on the server type, changing this property might open/close a network socket or otherwise toggle whether the server will process incoming requests.



property Active:


DefaultResponse   protected     (declared in TROServer)



property DefaultResponse: string read write


Dispatchers     (declared in TROServer)

Specifies how incoming requests will be processed and dispatched. Depending on the server type, one or multiple dispatchers can be configured to receive messages from the client. Each dispatcher consists of a Message and an optional Name. Also, each dispatcher can be individually enabled or disabled. Each server must have at least one dispatcher configured, in order to be able to process messages.

Essential Sub-Properties
  • Message specifies the message format to be used for this dispatcher.
  • Name specifies the name, or possibly the URL for the dispatcher.

In HTTP based servers (such as the TROIndyHTTPServer, the Name will be appended as folder to the server URL allowing the server to make multiple dispatchers available at different URLs.



property Dispatchers: TROMessageDispatchers read write


Encryption obsolete     (declared in TROBaseConnection)

This is DES based enscryption, it is obsolete because works only for Delphi. Use message envelope AES Encryption Envelope instead.



property Encryption: TROEncryption read write


Port   protected     (declared in TROServer)



property Port: Integer read write


ServeRodl     (declared in TROServer)



property ServeRodl: Boolean read write


Instance Methods

constructor Create   override     (declared in TROServer)



constructor Create(aOwner: TComponent)


Parameters:

  • aOwner:


destructor Destroy   override     (declared in TROServer)



destructor Destroy


Assign   override     (declared in TROServer)



procedure Assign(Source: TPersistent)


Parameters:

  • Source:


CheckProperties   virtual     (declared in TROServer)



procedure CheckProperties


DispatchMessage (IROTransport, TStream, TStream): boolean   protected overload     (declared in TROServer)



function DispatchMessage(const aTransport: IROTransport; aRequeststream: TStream; aResponsestream: TStream): boolean


Parameters:

  • aTransport:
  • aRequeststream:
  • aResponsestream:


DispatchMessage (IROTransport, TStream, TStream, TROResponseOptions): boolean   protected overload     (declared in TROServer)



function DispatchMessage(const aTransport: IROTransport; aRequeststream: TStream; aResponsestream: TStream; out oResponseOptions: TROResponseOptions): boolean


Parameters:

  • aTransport:
  • aRequeststream:
  • aResponsestream:
  • oResponseOptions:


DoAfterEncryptEvent   protected virtual obsolete     (declared in TROBaseConnection)



procedure DoAfterEncryptEvent(aEncryptedStream: TStream)


Parameters:

  • aEncryptedStream:


DoBeforeDecryptEvent   protected virtual obsolete     (declared in TROBaseConnection)



procedure DoBeforeDecryptEvent(aEncryptedStream: TStream)


Parameters:

  • aEncryptedStream:


DoDecryption   virtual obsolete     (declared in TROBaseConnection)



procedure DoDecryption(iCipherText: TStream; iPlainText: TStream)


Parameters:

  • iCipherText:
  • iPlainText:


DoDecryption2 obsolete     (declared in TROBaseConnection)



procedure DoDecryption2(const iStream: TStream)


Parameters:

  • iStream:


DoEncryption   virtual obsolete     (declared in TROBaseConnection)



procedure DoEncryption(iPlainText: TStream; iCipherText: TStream)


Parameters:

  • iPlainText:
  • iCipherText:


DoEncryption2 obsolete     (declared in TROBaseConnection)



procedure DoEncryption2(const iStream: TStream)


Parameters:

  • iStream:


EncodeEventStream   protected     (declared in TROServer)



procedure EncodeEventStream(aStream: TStream)


Parameters:

  • aStream:


GetDispatchersClass   protected virtual     (declared in TROServer)



function GetDispatchersClass: TROMessageDispatchersClass


GetPort   protected virtual     (declared in TROServer)



function GetPort: Integer


GetRODLReader   protected     (declared in TROServer)



function GetRODLReader: TROCustomRODLReader


GetServerType   protected virtual     (declared in TROServer)



function GetServerType: TROServerType


GetTransportObject   protected



function GetTransportObject: TObject


IntDispatchMessage   protected     (declared in TROServer)



function IntDispatchMessage(Dispatcher: TROMessageDispatcher; const aTransport: IROTransport; aRequeststream: TStream; aResponsestream: TStream; out oResponseOptions: TROResponseOptions): boolean


Parameters:

  • Dispatcher:
  • aTransport:
  • aRequeststream:
  • aResponsestream:
  • oResponseOptions:


IntGetActive   protected override



function IntGetActive: Boolean


IntSetActive   protected override



procedure IntSetActive(const Value: Boolean)


Parameters:

  • Value:


IsEncryptionUsed   protected     (declared in TROServer)



function IsEncryptionUsed: Boolean


Loaded   protected override     (declared in TROServer)



procedure Loaded


Notification   protected override     (declared in TROServer)



procedure Notification(AComponent: TComponent; Operation: TOperation)


Parameters:

  • AComponent:
  • Operation:


QueryInterface   protected override     (declared in TROServer)



function QueryInterface(const IID: TGUID; out Obj: ): HResult


Parameters:

  • IID:
  • Obj:


ROFreeNotification     (declared in TROComponent)



procedure ROFreeNotification(AComponent: TComponent)


Parameters:

  • AComponent:


RORemoveFreeNotification     (declared in TROComponent)



procedure RORemoveFreeNotification(AComponent: TComponent)


Parameters:

  • AComponent:


SendRemoveNotification   protected     (declared in TROComponent)



procedure SendRemoveNotification(AComponent: TComponent)


Parameters:

  • AComponent:


SendRequest



procedure SendRequest(aRequeststream: TStream; aResponsestream: TStream)


Parameters:

  • aRequeststream:
  • aResponsestream:


SetPort   protected virtual     (declared in TROServer)



procedure SetPort(const Value: Integer)


Parameters:

  • Value:


TriggerReadFromStream   protected     (declared in TROServer)



procedure TriggerReadFromStream(iStream: TStream)


Parameters:

  • iStream:


TriggerWriteToStream   protected     (declared in TROServer)



procedure TriggerWriteToStream(iStream: TStream)


Parameters:

  • iStream:


Events

onAfterEncrypt obsolete     (declared in TROBaseConnection)



property onAfterEncrypt: TROBaseConnectionOperation read write delegate: procedure Invoke(Sender: TROBaseConnection; aEncryptedStream: TStream)


OnAfterServerActivate     (declared in TROServer)

Fires after the server has been activated.



property OnAfterServerActivate: TNotifyEvent read write


OnAfterServerDeactivate     (declared in TROServer)

Fires after the server has been deactivated. You can use this event handler to perform any cleanup you might need after the server has stopped processing new requests.



property OnAfterServerDeactivate: TNotifyEvent read write


onBeforeDecrypt obsolete     (declared in TROBaseConnection)



property onBeforeDecrypt: TROBaseConnectionOperation read write delegate: procedure Invoke(Sender: TROBaseConnection; aEncryptedStream: TStream)


OnBeforeServerActivate     (declared in TROServer)

Fires just before the server is activated. You can use this event handler to perform any initialization you might need before the server starts processing new requests.



property OnBeforeServerActivate: TNotifyEvent read write


OnBeforeServerDeactivate     (declared in TROServer)

Fires just before the server is deactivated. You can use this event handler to perform any cleanup you might need before the server stops processing new requests.



property OnBeforeServerDeactivate: TNotifyEvent read write


OnGetRODLReader     (declared in TROServer)



property OnGetRODLReader: TROGetRODLReader read write delegate: procedure Invoke(Sender: TROServer; var aRODLReader: TROCustomRODLReader)


OnReadFromStream     (declared in TROServer)

Fires after a stream with a request message has been received from the client. The event handler can inspect and possibly modify the stream, before it continues to be processed by the higher levels of the RemObjects SDK framework.



property OnReadFromStream: TStreamOperation read write delegate: procedure Invoke(aStream: TStream)


OnWriteToStream     (declared in TROServer)

Fires just before a stream with a response message is sent back to the client. The event handler can inspect and possibly modify the stream, before it continues to be sent off to the client.



property OnWriteToStream: TStreamOperation read write delegate: procedure Invoke(aStream: TStream)


See Also


Product: RemObjects SDK
Available Editions: RemObjects SDK for .NET, Xcode, Delphi, Java and JavaScript

GlossaryArticlesLibrarySamples

Personal tools
Namespaces

Variants
Actions
Navigation
products
platforms
special
Toolbox