Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 3664 in orxonox.OLD


Ignore:
Timestamp:
Mar 30, 2005, 12:11:23 AM (19 years ago)
Author:
patrick
Message:

orxonox/trunk: doxygen comments for garbage collector

File:
1 edited

Legend:

Unmodified
Added
Removed
  • orxonox/trunk/src/garbage_collector.cc

    r3662 r3664  
    6565
    6666
     67/**
     68   \brief this sets the collection delay
     69   \param delay
     70   
     71   after this delay, the garbage collector starts its work and begins to collect unused object
     72   to delete them afterwards. only objects in the worldentity list from the world object are lookded
     73   at.
     74*/
    6775void GarbageCollector::setCollectionDelay(float delay)
    68 {}
     76{
     77  this->delay = delay;
     78}
    6979
    7080
     81/**
     82   \brief this foreces a garbage collection
     83
     84   if this function is called, the gc tries to initiate the garbage collection routines. actually
     85   this should always work.
     86*/
    7187void GarbageCollector::forceCollection()
    7288{
    73  
     89  /* just make the time slitely bigger than the delay */
     90  this->time = this->delay + 1;
     91  /* and update, to get rid of the unused objects */
     92  this->update();
    7493}
    7594
     95
     96/**
     97   \brief this ticks the GarbageCollector to give it the time pulse
     98   \param the time passed since last tick
     99
     100   like every other tick function eg. worldentity
     101*/
    76102void GarbageCollector::tick(float time)
    77103{
     
    80106
    81107
     108/**
     109   \brief this updated the gargabe collection, if the time is ready
     110
     111
     112*/
    82113void GarbageCollector::update()
    83114{
     
    101132          /* second remove out of pnode tree */
    102133          entity->remove();
    103           //NullParent* np = NullParent::getInstance();
    104           //np->removeChild(np);
    105          
    106134        }
    107135      entity = iterator->nextElement();
Note: See TracChangeset for help on using the changeset viewer.