EVENT::LCCollection Class Reference

The generic collection used in LCIO. More...

#include <pre-generated/EVENT/LCCollection.h>

Inheritance diagram for EVENT::LCCollection:
IMPL::LCCollectionVec IOIMPL::LCCollectionIOVec

List of all members.

Public Member Functions

virtual ~LCCollection ()
 Destructor.
virtual int getNumberOfElements () const =0
 Returns the number of elements in the collection.
virtual const std::string & getTypeName () const =0
 Returns the type name of the collection - valid names are defined in LCIO.
virtual LCObjectgetElementAt (int index) const =0
 Returns pointer to element at index - no range check, use getNumberOfEntries().
virtual int getFlag () const =0
 Returns flag word for collection.
virtual bool isTransient () const =0
 True if collection is transient, i.e.
virtual bool isDefault () const =0
 True if collection is the default collection for the given type.
virtual bool isSubset () const =0
 True if the collection holds a subset of objects from other collections.
virtual void addElement (LCObject *obj)=0
 Adds the given element to (end of) the collection.
virtual void removeElementAt (int i)=0
 Removes the i-th element from the collection.
virtual void setFlag (int flag)=0
 Set the flag word.
virtual const LCParametersgetParameters () const =0
 Parameters defined for this collection.
virtual LCParametersparameters ()=0
 Parameters defined for this collection.

Static Public Attributes

static const int BITTransient = 16
 Transient bit in flag word.
static const int BITDefault = 17
static const int BITSubset = 18

Detailed Description

The generic collection used in LCIO.

Holds arbitrary objects of type LCObject.

Author:
gaede
Version:
Id
LCCollection.aid,v 1.11 2005-03-02 16:22:58 gaede Exp
See also:
LCObject
LCIO

Member Function Documentation

virtual void EVENT::LCCollection::addElement ( LCObject obj  )  [pure virtual]

Adds the given element to (end of) the collection.

Throws an exception if the collection (event) is 'read only'.

Exceptions:
ReadOnlyException 

Implemented in IMPL::LCCollectionVec.

virtual int EVENT::LCCollection::getFlag (  )  const [pure virtual]
virtual int EVENT::LCCollection::getNumberOfElements (  )  const [pure virtual]
virtual bool EVENT::LCCollection::isDefault (  )  const [pure virtual]

True if collection is the default collection for the given type.

This implies that the collection is complete and unambigous. Convenient method that checks bit BITDefault of the flag word.

Implemented in IMPL::LCCollectionVec.

virtual bool EVENT::LCCollection::isSubset (  )  const [pure virtual]

True if the collection holds a subset of objects from other collections.

If the collection is not transient only the pointers/references to the original objects will be stored. Convenient method that checks bit BITSubset of the flag word.

Implemented in IMPL::LCCollectionVec.

virtual bool EVENT::LCCollection::isTransient (  )  const [pure virtual]

True if collection is transient, i.e.

will not be written to any LCIO file. Convenient method that checks bit BITTransient of the flag word.

Implemented in IMPL::LCCollectionVec.

Referenced by SIO::SIOWriter::setUpHandlers().

virtual LCParameters& EVENT::LCCollection::parameters (  )  [pure virtual]

Parameters defined for this collection.

Can be used to modify the collection paramters.

Implemented in IMPL::LCCollectionVec.

Referenced by UTIL::CellIDEncoder< T >::CellIDEncoder(), SIO::SIOVertexHandler::init(), SIO::SIOObjectHandler::init(), and SIO::SIOLCGenericObjectHandler::init().

virtual void EVENT::LCCollection::removeElementAt ( int  i  )  [pure virtual]

Removes the i-th element from the collection.

Throws an exception if the collection (event) is 'read only'.

Exceptions:
ReadOnlyException 

Implemented in IMPL::LCCollectionVec.

virtual void EVENT::LCCollection::setFlag ( int  flag  )  [pure virtual]

The documentation for this class was generated from the following file:
 All Classes Namespaces Functions Variables Typedefs Friends

Generated on 6 Mar 2020 for LCIO by  doxygen 1.6.1