Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: orxonox.OLD/orxonox/trunk/src/util/object_manager.cc @ 4940

Last change on this file since 4940 was 4940, checked in by bensch, 19 years ago

orxonox/trunk: moved the fast_factory to a file of its own.
This is because, the use is quite different from objectManager, and maybe we want to delete the ObjectManager totally from the Project
@patrick: can you please tell me what dou stink??

File size: 1.5 KB
RevLine 
[4592]1/*
[4245]2   orxonox - the future of 3D-vertical-scrollers
3
4   Copyright (C) 2004 orx
5
6   This program is free software; you can redistribute it and/or modify
7   it under the terms of the GNU General Public License as published by
8   the Free Software Foundation; either version 2, or (at your option)
9   any later version.
10
[4940]11### File Specific:
[4245]12   main-programmer: Patrick Boenzli
13*/
14
15#define DEBUG_SPECIAL_MODULE DEBUG_MODULE_OBJECT_MANAGER
16
17#include "object_manager.h"
[4288]18#include "garbage_collector.h"
[4286]19#include "list.h"
[4245]20
[4930]21#include "debug.h"
[4288]22
[4245]23using namespace std;
24
25/**
[4836]26 *  standard constructor
[4245]27*/
[4592]28ObjectManager::ObjectManager ()
[4245]29{
[4320]30  this->setClassID(CL_OBJECT_MANAGER, "ObjectManager");
[4597]31  this->setName("ObjectManager");
[4592]32
[4245]33}
34
[4322]35
[4245]36/**
[4836]37 *  the singleton reference to this class
[4245]38*/
39ObjectManager* ObjectManager::singletonRef = NULL;
40
41/**
[4836]42 *  standard deconstructor
[4245]43*/
[4592]44ObjectManager::~ObjectManager ()
[4245]45{
46  ObjectManager::singletonRef = NULL;
[4285]47}
[4245]48
[4485]49/**
[4836]50 *  outputs some simple debug information about the ObjectManage
[4485]51*/
[4746]52void ObjectManager::debug() const
[4287]53{
54  PRINT(0)("\n==========================| ObjectManager::debug() |===\n");
[4932]55/* PRINT(0)("=  Number of registerable classes: %i\n", CL_NUMBER );
56 PRINT(0)("=  Currently cached objects: \n");
57 for(int i = 0; i < CL_NUMBER; ++i)
58   {
[4318]59      if( this->managedObjectList[i] != NULL)
[4592]60        PRINT(0)("=   o Class Nr. %i has cached %i object(s)\n", i, this->managedObjectList[i]->getSize());
[4287]61      else
[4592]62        PRINT(0)("=   o Class Nr. %i has cached 0 object(s)\n", i);
[4932]63    }*/
[4287]64  PRINT(0)("=======================================================\n");
65}
[4930]66
[4931]67
Note: See TracBrowser for help on using the repository browser.