Package: ASCL.SV.Agent

Last update: 28 Sep 99 / 00:35


Overview

This class is used to implement the client session within the server framework as ASCL.SV.Server.


Synopsis

type Object is abstract tagged null record; type Reference is access all Object 'Class;

procedure Initialize( O : in out Object) is abstract; procedure Finalize( O : in out Object ) is abstract;

function Process( O : in Object; Data : in Stream_Element_Array ) return Stream_Element_Array is abstract;

End_Of_Processing : exception;

Description

Object

This type represents the instance data for a server session, called agent.

Reference

This type is used to reference all from Object derived types via access types.


Initialize

Preconditions:

The instance is not yet initialized.

Postconditions:

The instance is initialized.

Function:

This function may be used to initialize the agent (session) data. The exact functionality depends on the implementation of the agent it self and is there for out of scope of this section.

Exceptions:

ASCL.Usage_Error - Instance it already intitalized.


Finalize

Preconditions:

Postconditions:

Function:

Exceptions:


Process

Preconditions:

Server and Agent Object are initialized.

Postconditions:

Function:

This procedure has to be provided by the implementation. It is called upon reception of a package from the server connection. The procedure has two argument, the object data which may contain per session state information and the data package ist self.

If the session agent decides to terminate the session the exception End_Of_Processing should be raised.

Exceptions:

End_Of_Processing

Usage_Error


Discussion


References

ASCL

ASCL.SV

ASCL.SV.Server