| 1 |
NAME SoSFEnum SoSEnum "" { |
| 2 |
field containing an enumerated value |
| 3 |
} |
| 4 |
DESC { |
| 5 |
A single-value field that contains an enumerated type |
| 6 |
value, stored as an integer. Nodes that use this field class define |
| 7 |
mnemonic names for the values. These names should be used when setting |
| 8 |
or testing the values of the field, even though the values are treated |
| 9 |
as integers in the methods. |
| 10 |
\p |
| 11 |
\cSoSFEnums\. are written to file as a |
| 12 |
mnemonic enumerated type name. The name differs among uses of this |
| 13 |
field in various node or engine classes. See the man pages for |
| 14 |
specific nodes or engines |
| 15 |
for the names (e.g. \cSoDrawStyle\.). |
| 16 |
} |
| 17 |
|
| 18 |
METHOD setStr void setValue(const SbName &name) { |
| 19 |
Sets this field to contain the given mnemonic name, passed in as a |
| 20 |
name or string. |
| 21 |
} |
| 22 |
|
| 23 |
ALSO { SoField, SoSField, SoMFEnum } |
| 24 |
METHOD "" static SoType getClassTypeId() {} |
| 25 |
METHOD "" virtual void getTypeId() const { |
| 26 |
Returns the type for this class or a particular object of this class. |
| 27 |
} |
| 28 |
METHOD Get int getValue() const { |
| 29 |
Returns this field's value. |
| 30 |
} |
| 31 |
METHOD " " int operator =(int newValue) {} |
| 32 |
METHOD Set void setValue(int newValue) { |
| 33 |
Sets this field to \anewValue\.. |
| 34 |
} |
| 35 |
METHOD IsEq int operator ==(const SoSFEnum &f) const {} |
| 36 |
METHOD IsNEq int operator !=(const SoSFEnum &f) const { |
| 37 |
Returns TRUE if \af\. is of the same type and has the same value as this |
| 38 |
field. |
| 39 |
} |