OGRE  2.0
Object-Oriented Graphics Rendering Engine
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
Ogre::IdObject Class Reference

#include <OgreId.h>

+ Inheritance diagram for Ogre::IdObject:

Public Member Functions

 IdObject (IdType id)
 We don't call generateNewId() here, to prevent objects in the stack (i.e. More...
 
IdType getId () const
 Get the unique id of this object. More...
 
bool operator() (const IdObject *left, const IdObject *right)
 
bool operator() (const IdObject &left, const IdObject &right)
 

Protected Member Functions

void _setId (IdType newId)
 In the rare case our derived class wants to override our Id (normally we don't want that, that's why it's private). More...
 

Private Attributes

IdType mId
 

Friends

struct IdCmp
 

Detailed Description

Definition at line 53 of file OgreId.h.

Constructor & Destructor Documentation

Ogre::IdObject::IdObject ( IdType  id)
inline

We don't call generateNewId() here, to prevent objects in the stack (i.e.

local variables) that don't need an Id from incrementing the count; which is very dangerous if the caller is creating local objects from multiple threads (which should stay safe!). Instead our creator should do that.

Definition at line 71 of file OgreId.h.

Member Function Documentation

void Ogre::IdObject::_setId ( IdType  newId)
inlineprotected

In the rare case our derived class wants to override our Id (normally we don't want that, that's why it's private).

Definition at line 63 of file OgreId.h.

IdType Ogre::IdObject::getId ( ) const
inline

Get the unique id of this object.

Definition at line 74 of file OgreId.h.

bool Ogre::IdObject::operator() ( const IdObject left,
const IdObject right 
)
inline

Definition at line 76 of file OgreId.h.

References mId.

bool Ogre::IdObject::operator() ( const IdObject left,
const IdObject right 
)
inline

Definition at line 81 of file OgreId.h.

References mId.

Friends And Related Function Documentation

friend struct IdCmp
friend

Definition at line 56 of file OgreId.h.

Member Data Documentation

IdType Ogre::IdObject::mId
private

Definition at line 57 of file OgreId.h.

Referenced by operator()().


The documentation for this class was generated from the following file: