39 #ifndef _ObjectListBase_H__ 40 #define _ObjectListBase_H__ 62 virtual void changeContext(
Context* oldContext,
Context* newContext) = 0;
70 void removeFromList();
92 this->removeFromList();
134 size_t size()
const {
return this->size_; }
148 for (
unsigned int i = 0; i < this->listeners_.size(); ++i)
150 if (listeners_[i] == listener)
152 listeners_.erase(listeners_.begin() + i);
ObjectListBaseElement * rbegin() const
Returns a pointer to the last element in the list. Works only with Iterator.
Definition: ObjectListBase.h:141
ObjectListBase * getObjectList(const Identifier *identifier)
Definition: Context.cc:93
ObjectListBaseElement * last_
The last element in the list.
Definition: ObjectListBase.h:162
The list-element that actually contains the object.
Definition: CorePrereqs.h:208
Listable * objectBase_
The object.
Definition: ObjectListBase.h:66
Listable stores the entries of all object lists pointing to this instance.
Definition: Listable.h:50
Shared library macros, enums, constants and forward declarations for the core library ...
ObjectListBaseElement(Listable *object)
Constructor: Creates the list-element with an object.
Definition: ObjectListBase.h:59
Gets called by the object list if an element is removed.
Definition: ObjectListBase.h:103
ObjectListBaseElement * end() const
Returns a pointer to the element after the last element in the list. Works only with Iterator...
Definition: ObjectListBase.h:139
The ObjectListBase contains all objects of a given class.
Definition: ObjectListBase.h:125
ObjectListBaseElement * begin() const
Returns a pointer to the first element in the list. Works only with Iterator.
Definition: ObjectListBase.h:137
T * object_
The object.
Definition: ObjectListBase.h:95
ObjectListBaseElement * prev_
The previous element in the list.
Definition: ObjectListBase.h:65
size_t size_
The number of elements in the list.
Definition: ObjectListBase.h:163
ObjectListElement(T *object)
Definition: ObjectListBase.h:82
Die Wagnis Klasse hat die folgenden Aufgaben:
Definition: ApplicationPaths.cc:66
#define _CoreExport
Definition: CorePrereqs.h:61
virtual ~ObjectListBaseElement()
Definition: ObjectListBase.h:60
Definition: InputPrereqs.h:78
ObjectListBaseElement * first_
The first element in the list.
Definition: ObjectListBase.h:161
size_t size() const
Definition: ObjectListBase.h:134
virtual void changeContext(Context *oldContext, Context *newContext) override
Definition: ObjectListBase.h:84
std::vector< ObjectListElementRemovalListener * > listeners_
A list of Iterators pointing on an element in this list.
Definition: ObjectListBase.h:164
The list-element of the ObjectListBase.
Definition: ObjectListBase.h:52
ObjectListBaseElement * next_
The next element in the list.
Definition: ObjectListBase.h:64
ObjectListBaseElement * rend() const
Returns a pointer to the element in front of the first element in the list. Works only with Iterator...
Definition: ObjectListBase.h:143
void registerRemovalListener(ObjectListElementRemovalListener *listener)
Definition: ObjectListBase.h:145
void unregisterRemovalListener(ObjectListElementRemovalListener *listener)
Definition: ObjectListBase.h:146
void addObject(T *object)
Definition: Context.h:65
ObjectListBase * list_
The list.
Definition: ObjectListBase.h:67