Field containing a a node. More...
#include <Inventor/fields/SoSFNode.h>
Public Member Functions | |
virtual SoType | getTypeId () const |
const SoSFNode & | operator= (const SoSFNode &f) |
SoSFNode () | |
virtual | ~SoSFNode () |
SoNode * | getValue () const |
void | setValue (SoNode *newValue) |
SoNode * | operator= (SoNode *newValue) |
int | operator== (const SoSFNode &f) const |
int | operator!= (const SoSFNode &f) const |
virtual size_t | getValueSize () const |
SoNode * | getValue (SbBool getEffectiveNode=FALSE) |
Static Public Member Functions | |
static SoType | getClassTypeId () |
Field containing a a node.
This field maintains a an SoNode instance, correctly maintaining its reference count.
SoSFNodes are written to file as the node they are containing. For example:
mySoSFNodeField Cube {}
is an SoSFNode field named 'mySoSFNodeField', referring to an SoCube node. If the node is used elsewhere, the regular DEF/USE instancing mechanism applies:
anotherSoSFNodeField USE topSeparator
is an SoSFNode field that refers to a node named 'topSeparator' that was DEF'ed earlier in the scene.
SoField, SoSField, SoMFNode, SoNode
SoSFNode::SoSFNode | ( | ) |
Default constructor.
virtual SoSFNode::~SoSFNode | ( | ) | [virtual] |
Destructor.
static SoType SoSFNode::getClassTypeId | ( | ) | [static] |
Returns the type identifier for this class.
Reimplemented from SoSField.
virtual SoType SoSFNode::getTypeId | ( | ) | const [virtual] |
Returns the type identifier for this specific instance.
Implements SoTypedObject.
Gets the value of this field.
The getEffectiveNode parameter is only used when the node in the field is a Proto. In this case, if the parameter is true then for convenience it returns the first child of the proto (the node the proto is pretending to be).
SoNode* SoSFNode::getValue | ( | ) | const [inline] |
Returns this field's value.
virtual size_t SoSFNode::getValueSize | ( | ) | const [inline, virtual] |
Get size of the value.
Reimplemented from SoField.
int SoSFNode::operator!= | ( | const SoSFNode & | f | ) | const [inline] |
Returns FALSE if otherField is of the same type and has the same value as this field.
Reimplemented from SoField.
int SoSFNode::operator== | ( | const SoSFNode & | f | ) | const |
Returns TRUE if otherField is of the same type and has the same value as this field.
Reimplemented from SoField.
void SoSFNode::setValue | ( | SoNode * | newValue | ) |
Sets this field to newValue.