#include <LATcomponentIterator.h>
Inheritance diagram for LATcomponentIterator:


Public Member Functions | |
| LATcomponentIterator (EBFevent *) | |
| Constructor initializing the iterator with an EBFevent. | |
| LATcomponentIterator () | |
| Do nothing constructor. | |
| unsigned | iterate (EBFevent *event) |
| Class for iterating over a EBF event contributionsIterate over the EBF contributions in an event. | |
| virtual int | handleError (EBFcontribution *contribution, unsigned code, unsigned p1=0, unsigned p2=0) const |
| Handle all errors possible in LATcomponentIterator. | |
| virtual int | handleError (EBFevent *event, unsigned code, unsigned p1=0, unsigned p2=0) const |
| Handle all errors possible in LATcomponentIterator. | |
| int | OSW (EBFevent *event, EBFcontribution *contribution) |
| Method to call back the application with an OSWcontribution. | |
| int | GLT (EBFevent *event, EBFcontribution *contribution) |
| Method to call back the application with an GLTcontribution. | |
| int | GEM (EBFevent *event, EBFcontribution *contribution) |
| Method to call back the application with an GEMcontribution. | |
| int | AEM (EBFevent *event, EBFcontribution *contribution) |
| Method to call back the application with an AEMcontribution. | |
| int | TEM (EBFevent *event, EBFcontribution *contribution) |
| Method that iterates over TEMcontributions, calling the application back. | |
| int | UDF (EBFevent *event, EBFcontribution *contribution) |
| Method to call back the application with an EBFcontribution when the contribution is unrecognized. | |
| int | CAL (EBFevent *event, TEMcontribution *contribution) |
| Method to call back the application with an CALcontribution. | |
| int | TKR (EBFevent *event, TEMcontribution *contribution) |
| Method to call back the application with an TKRcontribution. | |
| virtual int | UDFcomponent (EBFevent *event, EBFcontribution *contribution) |
| Default method called when the application doesn't supply a method to handle undefined EBFcontributions. | |
| virtual int | OSWcomponent (EBFevent *event, OSWcontribution *contribution) |
| Default method called when the application doesn't supply a method to handle OSWcontributions. | |
| virtual int | GLTcomponent (EBFevent *event, GLTcontribution *contribution) |
| Default method called when the application doesn't supply a method to handle GLTcontributions. | |
| virtual int | GEMcomponent (EBFevent *event, GEMcontribution *contribution) |
| Default method called when the application doesn't supply a method to handle GEMcontributions. | |
| virtual int | ACDcomponent (EBFevent *event, AEMcontribution *contribution) |
| Default method called when the application doesn't supply a method to handle AEMcontributions. | |
| virtual int | CALcomponent (EBFevent *event, CALcontribution *contribution) |
| Default method called when the application doesn't supply a method to handle CALcontributions. | |
| virtual int | TKRcomponent (EBFevent *event, TKRcontribution *contribution) |
| Default method called when the application doesn't supply a method to handle TKRcontributions. | |
| virtual int | diagnostic (EBFevent *event, TEMcontribution *contribution) |
| Default method called when the application doesn't supply a method to handle diagnostic contributions. | |
| virtual int | error (EBFevent *event, TEMcontribution *contribution) |
| Default method called when the application doesn't supply a method to handle error contributions. | |
| virtual int | cleanup (EBFevent *event, TEMcontribution *contribution) |
| Default method called when the application doesn't supply a "cleanup" method. | |
The idea behind this class was to make one iterator that runs over all components of the event, calling all the subiterators necessary to parse the event in the finest detail. The user of this class only had to provide the virtual methods for those leaf iterators in which his application is interested. Those in which he is not intersted are defaulted to no-op methods to make this a concrete class.
Another consideration is that it appears that having the CPU cross the C++/Python boundary is an expensive operation, so in order to minimize the impact of this, as much as possible was done on the C++ side.
The conflict is that each time additional iterators are created the class interface changes, causing backward compatibility problems. For the moment (March 10, 2004), this class is set up to only do the first layers of iteration, leaving iteration down to the leaf items up to the application.
Copyright: Copyright 2004 by The Board of Trustees of the Leland Stanford Junior University. All rights reserved.
| LATcomponentIterator::LATcomponentIterator | ( | EBFevent * | event | ) | [inline] |
| int LATcomponentIterator::ACDcomponent | ( | EBFevent * | event, | |
| AEMcontribution * | contribution | |||
| ) | [inline, virtual] |
Default method called when the application doesn't supply a method to handle AEMcontributions.
| event | - The EBFevent containing the AEMcontribution | |
| contribution | - The AEMcontribution |
| int LATcomponentIterator::AEM | ( | EBFevent * | event, | |
| EBFcontribution * | contribution | |||
| ) | [inline, virtual] |
Method to call back the application with an AEMcontribution.
With this example class, this method is called by the EBFcontributionIterator. It should not be called from the application that instantiates this class.
| event | - The EBFevent containing the contribution | |
| contribution | - The EBFcontribution to handle as an AEMcontribution |
Implements EBFcontributionIterator.
| int LATcomponentIterator::CAL | ( | EBFevent * | event, | |
| TEMcontribution * | contribution | |||
| ) | [inline, virtual] |
Method to call back the application with an CALcontribution.
With this example class, this method is called by the TEMcontributionIterator. It should not be called from the application that instantiates this class.
| event | - The EBFevent containing the contribution | |
| contribution | - The EBFcontribution to handle as an CALcontribution |
Implements TEMcontributionIterator.
| int LATcomponentIterator::CALcomponent | ( | EBFevent * | event, | |
| CALcontribution * | contribution | |||
| ) | [inline, virtual] |
Default method called when the application doesn't supply a method to handle CALcontributions.
| event | - The EBFevent containing the CALcontribution | |
| contribution | - The CALcontribution |
| int LATcomponentIterator::cleanup | ( | EBFevent * | event, | |
| TEMcontribution * | contribution | |||
| ) | [inline, virtual] |
Default method called when the application doesn't supply a "cleanup" method.
The "cleanup" method is used to do additional checking on data following the last contribution in the event. In some examples, it is used to verify that the event is padded out to a LATp cell boundary with zeros.
| event | - The EBFevent containing the contribution | |
| contribution | - The EBFcontribution to handle as an EBFcontribution |
Implements TEMcontributionIterator.
| int LATcomponentIterator::diagnostic | ( | EBFevent * | event, | |
| TEMcontribution * | contribution | |||
| ) | [inline, virtual] |
Default method called when the application doesn't supply a method to handle diagnostic contributions.
| event | - The EBFevent containing the diagnostic contribution | |
| contribution | - The TEMcontribution |
Implements TEMcontributionIterator.
| int LATcomponentIterator::error | ( | EBFevent * | event, | |
| TEMcontribution * | contribution | |||
| ) | [inline, virtual] |
Default method called when the application doesn't supply a method to handle error contributions.
| event | - The EBFevent containing the error contribution | |
| contribution | - The TEMcontribution |
Implements TEMcontributionIterator.
| int LATcomponentIterator::GEM | ( | EBFevent * | event, | |
| EBFcontribution * | contribution | |||
| ) | [inline, virtual] |
Method to call back the application with an GEMcontribution.
With this example class, this method is called by the EBFcontributionIterator. It should not be called from the application that instantiates this class.
| event | - The EBFevent containing the contribution | |
| contribution | - The EBFcontribution to handle as a GEMcontribution |
Implements EBFcontributionIterator.
| int LATcomponentIterator::GEMcomponent | ( | EBFevent * | event, | |
| GEMcontribution * | contribution | |||
| ) | [inline, virtual] |
Default method called when the application doesn't supply a method to handle GEMcontributions.
| event | - The EBFevent containing the GEMcontribution | |
| contribution | - The GEMcontribution |
| int LATcomponentIterator::GLT | ( | EBFevent * | event, | |
| EBFcontribution * | contribution | |||
| ) | [inline, virtual] |
Method to call back the application with an GLTcontribution.
With this example class, this method is called by the EBFcontributionIterator. It should not be called from the application that instantiates this class.
| event | - The EBFevent containing the contribution | |
| contribution | - The EBFcontribution to handle as a GLTcontribution |
Implements EBFcontributionIterator.
| int LATcomponentIterator::GLTcomponent | ( | EBFevent * | event, | |
| GLTcontribution * | contribution | |||
| ) | [inline, virtual] |
Default method called when the application doesn't supply a method to handle GLTcontributions.
| event | - The EBFevent containing the GLTcontribution | |
| contribution | - The GLTcontribution |
| int LATcomponentIterator::handleError | ( | EBFevent * | event, | |
| unsigned | code, | |||
| unsigned | p1 = 0, |
|||
| unsigned | p2 = 0 | |||
| ) | const [inline, virtual] |
Handle all errors possible in LATcomponentIterator.
This method is used to handle errors occurring during the iteration over an LATcomponent. By default it does nothing, however it is virtual and is able to be overridden by the user.
| event | The event in error | |
| code | The error code | |
| p1 | a parameter associated with the error code | |
| p2 | a parameter associated with the error code |
Reimplemented from EBFcontributionIterator.
| int LATcomponentIterator::handleError | ( | EBFcontribution * | contribution, | |
| unsigned | code, | |||
| unsigned | p1 = 0, |
|||
| unsigned | p2 = 0 | |||
| ) | const [inline, virtual] |
Handle all errors possible in LATcomponentIterator.
This method is used to handle errors occurring during the iteration over an LATcomponent. By default it does nothing, however it is virtual and is able to be overridden by the user.
| contribution | The contribution in error | |
| code | The error code | |
| p1 | a parameter associated with the error code | |
| p2 | a parameter associated with the error code |
| unsigned LATcomponentIterator::iterate | ( | EBFevent * | event | ) | [inline] |
Class for iterating over a EBF event contributionsIterate over the EBF contributions in an event.
This method calls back a virtual contribution handlers for each contribution it finds. Which handler is called back is determined by the contribution source ID and the _map method. Contribution handlers take the event and the contribution as arguments.
| event | A pointer to the EBFevent to be iterated over |
Reimplemented from EBFcontributionIterator.
| int LATcomponentIterator::OSW | ( | EBFevent * | event, | |
| EBFcontribution * | contribution | |||
| ) | [inline, virtual] |
Method to call back the application with an OSWcontribution.
With this example class, this method is called by the EBFcontributionIterator. It should not be called from the application that instantiates this class.
| event | - The EBFevent containing the contribution | |
| contribution | - The EBFcontribution to handle as an OSWcontribution |
Implements EBFcontributionIterator.
| int LATcomponentIterator::OSWcomponent | ( | EBFevent * | event, | |
| OSWcontribution * | contribution | |||
| ) | [inline, virtual] |
Default method called when the application doesn't supply a method to handle OSWcontributions.
| event | - The EBFevent containing the OSWcontribution | |
| contribution | - The OSWcontribution |
| int LATcomponentIterator::TEM | ( | EBFevent * | event, | |
| EBFcontribution * | contribution | |||
| ) | [inline, virtual] |
Method that iterates over TEMcontributions, calling the application back.
With this example class, this method is called by the EBFcontributionIterator. It should not be called from the application that instantiates this class.
| event | - The EBFevent containing the contribution | |
| contribution | - The EBFcontribution to handle as a TEMcontribution |
Implements EBFcontributionIterator.
| int LATcomponentIterator::TKR | ( | EBFevent * | event, | |
| TEMcontribution * | contribution | |||
| ) | [inline, virtual] |
Method to call back the application with an TKRcontribution.
With this example class, this method is called by the TEMcontributionIterator. It should not be called from the application that instantiates this class.
| event | - The EBFevent containing the contribution | |
| contribution | - The EBFcontribution to handle as an TKRcontribution |
Implements TEMcontributionIterator.
| int LATcomponentIterator::TKRcomponent | ( | EBFevent * | event, | |
| TKRcontribution * | contribution | |||
| ) | [inline, virtual] |
Default method called when the application doesn't supply a method to handle TKRcontributions.
| event | - The EBFevent containing the TKRcontribution | |
| contribution | - The TKRcontribution |
| int LATcomponentIterator::UDF | ( | EBFevent * | event, | |
| EBFcontribution * | contribution | |||
| ) | [inline, virtual] |
Method to call back the application with an EBFcontribution when the contribution is unrecognized.
With this example class, this method is called by the EBFcontributionIterator. It should not be called from the application that instantiates this class.
| event | - The EBFevent containing the contribution | |
| contribution | - The undefined EBFcontribution |
Implements EBFcontributionIterator.
| int LATcomponentIterator::UDFcomponent | ( | EBFevent * | event, | |
| EBFcontribution * | contribution | |||
| ) | [inline, virtual] |
Default method called when the application doesn't supply a method to handle undefined EBFcontributions.
| event | - The EBFevent containing the EBFcontribution | |
| contribution | - The EBFcontribution |
1.4.7