Next: Multiple Algorithms
Up: Modules, Supermodules and Context
Previous: TPhModuleContext
  Contents
Communication between modules is done
via the exchange of named objects
with the event and object manager. Modules therefore do not depend on
specific other modules being available in memory or having been run
before, but only on whether the necessary data objects have been stored
in the event or the object manager. This allows us to completely specify
a module by defining which objects or containers it expects as input
from the event and object manager and which objects are produced as output
in event and object manager. Any two objects using and producing the same
objects should be completely interchangeable in running macros.
The names of input and output objects for each module should be set to a
default value in the modules constructor. They can be overwritten at any time,
allowing the same module to be run on the same event
with different tuning parameters producing different output containers.
Using special tags in the comment fields of the module data member declaration
allows the programmer to identify the names of input and output containers.
This will be used to automatically check the availability of the containers
needed by the module, check whether a particular chain of modules is likely
to be consistent and provide automated module documentation.
As a rule of thumb, modules should exit gracefully and with a meaningful
error message if one of necessary input objects is not found in the event
or object manager.
Next: Multiple Algorithms
Up: Modules, Supermodules and Context
Previous: TPhModuleContext
  Contents
Gunther Roland
2000-05-05