SOSFENUM(3iv)

πŸ’– SoSFEnum β€” the field that holds an enum value, bestie πŸ’–

okay so this is the SoSFEnum(3IV) page, and honestly? it's giving "small but mighty". it's a field. it holds one enumerated value. that's the whole vibe. but the way it does it? iconic. ✨


🌸 INHERITS FROM 🌸

SoField > SoSField > SoSFEnum

family tree moment fr fr 🫢 β€” it's a grandbaby of SoField, and it came up through SoSField.


✨ SYNOPSIS ✨

πŸŽ€ Methods from class SoSFEnum

void                setValue(const SbName &name)
static SoType       getClassTypeId()
virtual void        getTypeId() const
int                 getValue() const
int                 operator =(int newValue)
void                setValue(int newValue)
int                 operator ==(const SoSFEnum &f) const
int                 operator !=(const SoSFEnum &f) const

πŸ¦‹ Methods from class SoField

void                setIgnored(SbBool ignore)
SbBool              isIgnored() const
SbBool              isDefault() const
virtual SbBool      isOfType(SoType type) const
SbBool              set(const char *valueString)
void                get(SbString &valueString)
void                touch()
SbBool              connectFrom(SoField *fromField)
SbBool              connectFrom(SoEngineOutput *fromEngine)
void                disconnect()
SbBool              isConnected() const
SbBool              isConnectedFromField() const
SbBool              getConnectedField(SoField *&writingField) const
SbBool              isConnectedFromEngine() const
SbBool              getConnectedEngine(SoEngineOutput *&engineOutput)
                         const
void                enableConnection(SbBool flag)
SbBool              isConnectionEnabled() const
int                 getForwardConnections(SoFieldList &list) const
SoFieldContainer *  getContainer() const

πŸ’… DESCRIPTION πŸ’…

so basically: this is a single-value field that holds an enumerated type value, and underneath it's stored as an integer. that's the whole deal. πŸ’€

but here's the ✨lore✨ β€” nodes that use this field class define mnemonic names for the values. and you should use those names when you're setting or testing the field's values, okay? even though the methods literally treat the values as integers. like yes the int is there. no you should not be out here using it. the names are the moment. πŸŽ€

SoSFEnums get written to file as a mnemonic enumerated type name ✨. and the name is gonna differ depending on which node or engine class is using this field. so like... don't assume. check the man pages for your specific nodes or engines to find the actual names (think SoDrawStyle β€” that's the example, bestie, not me making things up 🫢).


πŸ‘‘ METHODS πŸ‘‘

  • void setValue(const SbName &name) β€” sets this field to hold the given mnemonic name, handed to it as a name or a string. ✨
  • static SoType getClassTypeId()
  • virtual void getTypeId() const β€” these two return the type for this class, or for a particular object of this class. iykyk πŸ’…
  • int getValue() const β€” hands you back this field's value. that's it, that's the function. πŸŽ€
  • int operator =(int newValue)
  • void setValue(int newValue) β€” sets this field to newValue. slay. ✨
  • int operator ==(const SoSFEnum &f) const
  • int operator !=(const SoSFEnum &f) const β€” returns TRUE if f is of the same type and has the same value as this field. both conditions, no shortcuts. πŸ‘‘

🌈 SEE ALSO 🌈

SoField, SoSField, SoMFEnum


ngl bestie, if you were looking for the multi-value version, that's SoMFEnum and she's right there in SEE ALSO. this one is the single-value girlie. πŸ’–

okay that's the whole page, mwah 🫢 this lil doc came to you as part of the SoSFEnum(3IV) manual page β€” that's the 3IV manual, and the source/version tag on the footer is SoSFEnum(3IV)(). periodt. ✨🌸πŸ’