LCIO  "2.7.4"
 All Classes Namespaces Functions Variables Typedefs Friends Pages
LCCollection.h
1 // -*- C++ -*-
2 // AID-GENERATED
3 // =========================================================================
4 // This class was generated by AID - Abstract Interface Definition
5 // DO NOT MODIFY, but use the org.freehep.aid.Aid utility to regenerate it.
6 // =========================================================================
7 #ifndef EVENT_LCCOLLECTION_H
8 #define EVENT_LCCOLLECTION_H 1
9 
10 #include <string>
11 
12 #include "EVENT/LCParameters.h"
13 #include "Exceptions.h"
14 
15 namespace EVENT {
16 
17 class LCObject;
18 
29 class LCCollection {
30 
31 public:
33  virtual ~LCCollection() { /* nop */; }
34 
38  virtual int getNumberOfElements() const = 0;
39 
42  virtual const std::string & getTypeName() const = 0;
43 
46  virtual LCObject * getElementAt(int index) const = 0;
47 
62  virtual int getFlag() const = 0;
63 
68  static const int BITTransient = 16 ;
69  static const int BITDefault = 17 ;
70  static const int BITSubset = 18 ;
74  virtual bool isTransient() const = 0;
75 
80  virtual bool isDefault() const = 0;
81 
87  virtual bool isSubset() const = 0;
88 
94  virtual void addElement(LCObject * obj) throw (ReadOnlyException, std::exception ) = 0;
95 
101  virtual void removeElementAt(int i) throw (ReadOnlyException, std::exception ) = 0;
102 
105  virtual void setFlag(int flag) = 0;
106 
109  virtual const LCParameters & getParameters() const = 0;
110 
114  virtual LCParameters & parameters() = 0;
115 }; // class
116 } // namespace EVENT
117 #endif /* ifndef EVENT_LCCOLLECTION_H */
The generic object that is held in an LCCollection.
Definition: LCObject.h:30
virtual bool isTransient() const =0
True if collection is transient, i.e.
virtual void setFlag(int flag)=0
Set the flag word.
virtual void removeElementAt(int i)=0
Removes the i-th element from the collection.
virtual LCObject * getElementAt(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.
static const int BITTransient
Transient bit in flag word.
Definition: LCCollection.h:68
virtual LCParameters & parameters()=0
Parameters defined for this collection.
virtual void addElement(LCObject *obj)=0
Adds the given element to (end of) the collection.
Simple interface to store generic named parameters of type int, float and string. ...
Definition: LCParameters.h:28
virtual bool isSubset() const =0
True if the collection holds a subset of objects from other collections.
virtual const std::string & getTypeName() const =0
Returns the type name of the collection - valid names are defined in LCIO.
virtual int getNumberOfElements() const =0
Returns the number of elements in the collection.
The generic collection used in LCIO.
Definition: LCCollection.h:29
virtual ~LCCollection()
Destructor.
Definition: LCCollection.h:33
virtual bool isDefault() const =0
True if collection is the default collection for the given type.
virtual const LCParameters & getParameters() const =0
Parameters defined for this collection.
EventException used for signaling a 'read only exception'.
Definition: Exceptions.h:74