cgma
Enum-Iterators

Convenience macros for iterating over all possible values in an enum. More...

#define IBASE_MINENUM(enumName)   enumName ## _MIN
#define IBASE_MAXENUM(enumName)   enumName ## _MAX
#define IBASE_NUMENUM(enumName)   ((int)IBASE_MAXENUM(enumName) - (int)IBASE_MINENUM(enumName) + 1)
#define IBASE_INCENUM(enumName, I)   (I = (enum enumName)((int)I+1))

Detailed Description

Convenience macros for iterating over all possible values in an enum.

These convenience macros are provided to facilitate iterating over all possible values in an enumerated type. To use these macros, for example...

Be aware that some enumerated types include a wild card often used in queries to represent all possible values and you may or may not want to include such a value in your iteration.


Define Documentation

#define IBASE_INCENUM (   enumName,
 
)    (I = (enum enumName)((int)I+1))

Definition at line 91 of file iGeom.h.

#define IBASE_MAXENUM (   enumName)    enumName ## _MAX

Definition at line 89 of file iGeom.h.

#define IBASE_MINENUM (   enumName)    enumName ## _MIN

Definition at line 88 of file iGeom.h.

#define IBASE_NUMENUM (   enumName)    ((int)IBASE_MAXENUM(enumName) - (int)IBASE_MINENUM(enumName) + 1)

Definition at line 90 of file iGeom.h.

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines