120 {
return (storage.index == 0); }
147 {
return (storage.index == t.storage.
index);}
150 {
return (storage.index != t.storage.
index);}
155 {
return (storage.index < t.storage.
index); }
161 void * (*createMethod)() = NULL,
170 void * (*createMethod)() = NULL);
177 short getData()
const {
return storage.data; }
180 short getKey()
const {
return storage.index; }
204 static int nextIndex;
205 static int arraySize;
206 static SoTypeData *typeData;
208 static void expandTypeData();
#define SoEXTENDER
Provide inline template functions for abs, swap, min, max, and clamp.
INVENTOR_API bool operator!=(const SbBox3f &b1, const SbBox3f &b2)
INVENTOR_API bool operator==(const SbBox3f &b1, const SbBox3f &b2)
#define INVENTOR_API
Disable some annoying warnings on MSVC 6.
This is a dictionary mapping (size_t) integer keys to (void *) data pointers.
Character string stored in a hash table.
Maintains a list of SoTypes.
SoType has no virtual functions to keep it small...
static SoType fromName(SbName name)
Returns the type associated with the given name.
static int getAllDerivedFrom(SoType type, SoTypeList &list)
Adds all types derived from the given type to the given type list.
bool isDerivedFrom(SoType t) const
Returns TRUE if the type is derived from type t.
unsigned int isPublic
0 if is an internal class
unsigned int index
Assumes we have fewer than 32,768 types.
short getData() const
Get data.
void makeInternal()
Mark this type as internal; if internal, getAllDerivedFrom and fromName will not return the type.
void * createInstance() const
Creates and returns a pointer to an instance of the type.
bool isBad() const
Returns TRUE if the type is a bad type.
static SoType overrideType(SoType existingType, void *(*createMethod)()=NULL)
Make an new type act like an existing type.
bool canCreateInstance() const
Some types are able to create instances; for example, most nodes and engines (those which are not abs...
static SoType badType()
Returns an always-illegal type. Useful for returning errors.
static SoType createType(SoType parent, SbName name, void *(*createMethod)()=NULL, short data=0)
Create a new type.
SbName getName() const
Returns the name associated with a type.
short getKey() const
Returns the type key as a short.
static int getNumTypes()
Get the number of types currently registed in the types dictionary.
SoType getParent() const
Returns the type of the parent class.
static void init()
Initialize the type system.