In file fibersrv.hxx:

namespace vos class OFiberingServer : public NAMESPACE_VOS OReferenceCounter, public NAMESPACE_VOS OThread

OFiberingServer Depends on cooperative executing IExecutable-Objects

Inheritance:


Public Methods

void add (const ORef<IExecutable>& ref)
Adds an IExecutable to the server and starts calling its execute() method
void complete ()
Wait till all excutables are finished
ORef <IExecutable> getNextCompleted ()
Block until the next executable has finished and return a reference to it
OFiberingServer ()
Creates an empty fiberserver
void remove (const ORef<IExecutable>& ref)
Stops calling the the IExecutable and removes it from the server
~OFiberingServer ()
By destroying the OFiberServer, you also delete all its IExecutable-Objects

Documentation

OFiberingServer Depends on cooperative executing IExecutable-Objects. The OFiberingServer creates one thread where each IExecutables execute() method is called in turn. When an execute() returns False, the FiberServer assumes it is finished and stops calling it. As the FiberServer depends on the cooperative nature of the IExecutables, their execute()-methods should neither contain blocking functions nor should they be used to do very time-consuming task. If you need preemtive multitasking or want to use blocking calls, use a OThreadServer instead. Further ideas: - Include a sleep() operation (in IExecutable?) to tell the OFiberingServer not to call the IExecutable for some time. - Assign an delay/call-intervall attribute to the IExecutable, which tells the OFiberingServer/OThreadingServer to let the specified time pass doing something else before calling the executable again.
OFiberingServer()
Creates an empty fiberserver

~OFiberingServer()
By destroying the OFiberServer, you also delete all its IExecutable-Objects

void add(const ORef<IExecutable>& ref)
Adds an IExecutable to the server and starts calling its execute() method

void remove(const ORef<IExecutable>& ref)
Stops calling the the IExecutable and removes it from the server

void complete()
Wait till all excutables are finished

ORef <IExecutable> getNextCompleted()
Block until the next executable has finished and return a reference to it


This class has no child classes.
Author:
Bernd Hofner
Version:
0.1

alphabetic index hierarchy of classes


this page has been generated automatically by doc++

(c)opyright by Malte Zöckler, Roland Wunderling
contact: doc++@zib.de