12#ifndef ROOT_TOrdCollection
13#define ROOT_TOrdCollection
#define ClassDef(name, id)
const Bool_t kIterForward
Collection abstract base class.
Iterator abstract base class.
Mother of all ROOT objects.
Iterator of ordered collection.
void Reset()
Reset collection iterator.
const TCollection * GetCollection() const
Bool_t operator!=(const TIterator &aIter) const
This operator compares two TIterator objects.
const TOrdCollection * fCol
std::ptrdiff_t difference_type
TObject * Next()
Return next object in collection.
TIterator & operator=(const TIterator &rhs)
Overridden assignment operator.
TObject * operator*() const
Return current object or nullptr.
std::bidirectional_iterator_tag iterator_category
TObject * Remove(TObject *obj)
Remove object from collection.
Bool_t LowWaterMark() const
TOrdCollection(const TOrdCollection &)=delete
Int_t IndexOf(const TObject *obj) const
Return index of object in collection.
void Clear(Option_t *option="")
Remove all objects from the collection.
TObject * After(const TObject *obj) const
Return the object after object obj.
void AddBefore(const TObject *before, TObject *obj)
Insert object before object before in the collection.
TOrdCollection & operator=(const TOrdCollection &)=delete
void PutAt(TObject *obj, Int_t idx)
Put object at index idx. Overwrites what was at idx before.
void AddLast(TObject *obj)
Add object at the end of the collection.
~TOrdCollection()
Delete the collection.
Int_t PhysIndex(Int_t idx) const
void Sort()
If objects in collection are sortable (i.e.
TObject ** GetObjectRef(const TObject *obj) const
return address of pointer obj
void AddAt(TObject *obj, Int_t idx)
Insert object at position idx in the collection.
TObject * At(Int_t idx) const
Returns the object at position idx. Returns 0 if idx is out of range.
Int_t LogIndex(Int_t idx) const
TOrdCollectionIter Iterator_t
void AddFirst(TObject *obj)
Insert object at beginning of collection.
void AddAfter(const TObject *after, TObject *obj)
Insert object after object after in the collection.
void Init(Int_t capacity)
Initialize ordered collection.
Bool_t IllegalIndex(const char *method, Int_t idx) const
Return true when index out of bounds and print error.
TObject * RemoveAt(Int_t idx)
Remove object at index idx.
TObject * First() const
Return the first object in the collection.
TIterator * MakeIterator(Bool_t dir=kIterForward) const
Return an ordered collection iterator.
TObject * Before(const TObject *obj) const
Returns the object before object obj.
void MoveGapTo(Int_t newGapStart)
Move gap to new position.
Int_t BinarySearch(TObject *obj)
Find object using a binary search.
void Delete(Option_t *option="")
Remove all objects from the collection AND delete all heap based objects.
TObject * Last() const
Return the last object in the collection.
void SetCapacity(Int_t newCapacity)
Set/change ordered collection capacity.
Sequenceable collection abstract base class.