Main Page   Namespace List   Class Hierarchy   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages  

VTQL::CEModul Class Reference

Base class for all moduls, that handle events. More...

#include <vtql_event.h>

Inheritance diagram for VTQL::CEModul:

VTQL::CModul thread::CallBack::CBFunct VTQL::EM_PageAlevt List of all members.

Public Methods

virtual ~CEModul ()
 CEModul (Event_generic &event_con, const std::string &match, ShowMode mode)
 Send a command to a connection. More...

virtual bool Wait (bool block=true)
 Wait for a incomming event of our command. More...


Protected Methods

virtual void Handle (const Arg &p)=0
 Handle events of the command, that was sent by this instance. More...

void SetInvalid ()
 Mark the incomming page as invalid.


Detailed Description

Base class for all moduls, that handle events.

The main problem we have to handle, that you do never know whether

We simply compare the servers information about the command and the command that should be the source of the event and only call the Handle(const Arg&) method if anything is OK.


Constructor & Destructor Documentation

VTQL::CEModul::CEModul Event_generic   event_con,
const std::string &    match,
ShowMode    mode
 

Send a command to a connection.

It puts the command only into the output queue. Call Wait(bool) to try to send it. Of course we do the callback stuff right, so that we do not loose any event.

Parameters:
event_con  Connection where you want to get events
match  Events should match this (not escaped) match.
mode  The page_output_mode for events


Member Function Documentation

virtual bool VTQL::CEModul::Wait bool    block = true [virtual]
 

Wait for a incomming event of our command.

In detail, the event has to be read completly and must not be invalid (see SetInvalid()), to let this method return true. If you wait in blocking mode, it return always true.

Parameters:
block  switch blocking (true) or nonblocking (false) waiting.
Returns:
true if a matching event was recieved, false otherwise.

Reimplemented from VTQL::CModul.

virtual void VTQL::CEModul::Handle const Arg &    p [protected, pure virtual]
 

Handle events of the command, that was sent by this instance.

This gets only called, if the incomming event is of the specified type.

Parameters:
p  Pair of int (line number, starting with 1) and string (line content)


The documentation for this class was generated from the following file:
Generated on Sun Apr 14 17:37:04 2002 for libvtql by doxygen1.2.14 written by Dimitri van Heesch, © 1997-2002