Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changes between Initial Version and Version 1 of code/doc/ObjectList


Ignore:
Timestamp:
Feb 25, 2008, 12:56:57 AM (17 years ago)
Author:
landauf
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • code/doc/ObjectList

    v1 v1  
     1= !ObjectList =
     2
     3== Description ==
     4
     5The [wiki:ObjectList] is a double-linked list used to store all objects of a given class. It's nothing special, we might use std::list as well, but it ensures a very fast deletion of objects. Just think of the list of all [wiki:BaseObject BaseObjects]: There might be at least 10'000 objects. If deleting means: "Iterate through the list until you find the stored object" this could result in up to (10'000^2^ / 2 = 50 mio) iterations.
     6
     7The [wiki:ObjectList] allows you to delete an entry by simply connecting the previous and the following entry. The assiciated entries and the related [wiki:ObjectList ObjectLists] of each object are stored in a [wiki:MetaObjectList]. The list gets provided by [wiki:OrxonoxClass].
     8
     9List-elements can be assigned to an [wiki:Iterator]. This allows you to easily iterate through all objects in a [wiki:ObjectList]. Read the related Wiki-page for more informations.
     10
     11== Functions ==
     12 * '''begin()'''/'''start()''': Returns the first list-element of the list
     13 * '''end()''': Returns the last list-element of the list