Class AssociationManager
- Direct Known Subclasses:
- Cell, Cluster, Jet, ReconstructedParticle, Track
- class AssociationManager
This class has been provided as an interim solution to the
association problem.
It provides an implemetation of a general templated association\
mechanism which allows any object which inherits from ContainedObject
(A special Athena class used for items in the TES) to store a
reference to any other such object.
A user can then subsequently retrieve a SmartRefVector containing
SmartRefs to all stored associations or to a subset selected by
class type. Templates
have been used to avoid the user having to cast ContainedObject
to specific classes in the latter case.
Every user class which wishes to use this mechanism simply
inherits AssociationManager publically.
Field Summary |
protected SmartRefVector | m_associations This is the record of associations between ContainedObjects. |
Method Summary |
void | associate(const ContainedObject * otherEntity) Sets a simple one directional association between this entity
and another. |
SmartRefVector | associations() Returns a list of all entities associated with this object. |
SmartRefVector | associations(T ) Returns a list of all entities of a certain class which have
been associated with this object. |
bool | unAssociated() A quick way to find out whether there are any associations at all. |
m_associations
protected SmartRefVector m_associations
- This is the record of associations between ContainedObjects.
It is a vector of SmartRef pointing
polymorphically to other ContainedObjects in the TES.
associate
public void associate(const ContainedObject * otherEntity)
- Sets a simple one directional association between this entity
and another.
otherEntity is automatically converted to
SmartRef(otherEntity)
associations
public SmartRefVector associations()
- Returns a list of all entities associated with this object.
associations
public SmartRefVector associations(T )
- Returns a list of all entities of a certain class which have
been associated with this object.
T must inherit from ContainedObject
unAssociated
public bool unAssociated()
- A quick way to find out whether there are any associations at all.