TROEventWriter

Overview

The TROEventWriter is the ancestor classes that are used to send event messages from server to the client. Descendants of the TROEventWriter class are created in the auto-generated _Intf module (see more in Files Generated from RODL) if the event sinks are defined in the RODL library. These descendant classes are used in the repository for dispatching event messages.

You will not usually deal with the TROEventWriter class and its descendants directly; the Remoting SDK invocation framework will use them to execute procedures that are related with server events.

Location

Implements

 

constructor Create (IROMessage, boolean)    (declared in TROEventProxy)

Creates a new TROEventProxy object with the specified message aMessage. If the CloneMessage is true, the constructor creates a copy of the aMessage and saves it in the private variable fMessage. If the CloneMessage is false, the fMessage saves a reference of the aMessage.

constructor Create(const aMessage: IROMessage; CloneMessage: boolean)

Parameters:

  • aMessage: Specified message
  • CloneMessage: When true, a copy of the aMessage will be saved, otherwise a reference to the aMessage will be saved.

constructor Create (IROMessage, IROEventRepository)  reintroduce

Creates a new instance with the specified event message aMessage and the specified repository aRepository.

constructor Create(const aMessage: IROMessage; const aRepository: IROEventRepository)

Parameters:

  • aMessage: Event message.
  • aRepository: Specified repository that will store the event data and additional information.

ExcludeSender

Determines the need to use the sender session in the processing of the current event. If ExcludeSender is true (default value), the sender will not receive the event message, if ExcludeSender is false, the sender will receive the event message. For example: In the chat, you can exclude the client sender session from the mailing list.

property ExcludeSender: boolean read write

ExcludeSessionList

Determines the need to use the SessionList in the processing of the current event. If ExcludeSessionList is false, the SessionList should be used, if ExcludeSessionList is true, the SessionList should not be used.

property ExcludeSessionList: boolean read write

GetExcludeSessionList  protected

Gets the ExcludeSessionList property.

function GetExcludeSessionList: boolean

GetSessionList  protected

Gets the SessionList property.

function GetSessionList: TStrings

NewInstance  override    (declared in TROInterfacedObject)

Creates and returns a new instance of the interfaced object, initializing its reference counter with 1.

class function NewInstance: TObject

RefCount    (declared in TROInterfacedObject)

Provides read-only access to the reference counter. When this value reaches zero, the object is freed.

property RefCount: Integer read write

Repository  protected

Defines the repository that is associated with the current TROEventWriter object. The Repository is needed to store the event data with additional information.

property Repository: IROEventRepository read write

SessionList

Contains the list of the clients (their session GUID) that will receive the event message, if the ExcludeSessionList property equals false. For example: In the chat, the SessionList can contain the list of client sessions that will receive the message from the server.

property SessionList: TStrings read write

SetExcludeSessionList  protected

Sets the property ExcludeSessionList with specified Value.

procedure SetExcludeSessionList(const Value: boolean)

Parameters:

  • Value: False means that the SessionList should be used in the event processing, true that it should not be used.

 

ExcludeSender

Determines the need to use the sender session in the processing of the current event. If ExcludeSender is true (default value), the sender will not receive the event message, if ExcludeSender is false, the sender will receive the event message. For example: In the chat, you can exclude the client sender session from the mailing list.

property ExcludeSender: boolean read write

ExcludeSessionList

Determines the need to use the SessionList in the processing of the current event. If ExcludeSessionList is false, the SessionList should be used, if ExcludeSessionList is true, the SessionList should not be used.

property ExcludeSessionList: boolean read write

RefCount    (declared in TROInterfacedObject)

Provides read-only access to the reference counter. When this value reaches zero, the object is freed.

property RefCount: Integer read write

Repository  protected

Defines the repository that is associated with the current TROEventWriter object. The Repository is needed to store the event data with additional information.

property Repository: IROEventRepository read write

SessionList

Contains the list of the clients (their session GUID) that will receive the event message, if the ExcludeSessionList property equals false. For example: In the chat, the SessionList can contain the list of client sessions that will receive the message from the server.

property SessionList: TStrings read write

 

NewInstance  override    (declared in TROInterfacedObject)

Creates and returns a new instance of the interfaced object, initializing its reference counter with 1.

class function NewInstance: TObject

 

constructor Create (IROMessage, boolean)    (declared in TROEventProxy)

Creates a new TROEventProxy object with the specified message aMessage. If the CloneMessage is true, the constructor creates a copy of the aMessage and saves it in the private variable fMessage. If the CloneMessage is false, the fMessage saves a reference of the aMessage.

constructor Create(const aMessage: IROMessage; CloneMessage: boolean)

Parameters:

  • aMessage: Specified message
  • CloneMessage: When true, a copy of the aMessage will be saved, otherwise a reference to the aMessage will be saved.

constructor Create (IROMessage, IROEventRepository)  reintroduce

Creates a new instance with the specified event message aMessage and the specified repository aRepository.

constructor Create(const aMessage: IROMessage; const aRepository: IROEventRepository)

Parameters:

  • aMessage: Event message.
  • aRepository: Specified repository that will store the event data and additional information.

GetExcludeSessionList  protected

Gets the ExcludeSessionList property.

function GetExcludeSessionList: boolean

GetSessionList  protected

Gets the SessionList property.

function GetSessionList: TStrings

SetExcludeSessionList  protected

Sets the property ExcludeSessionList with specified Value.

procedure SetExcludeSessionList(const Value: boolean)

Parameters:

  • Value: False means that the SessionList should be used in the event processing, true that it should not be used.

Descendants

See Also