CSIBCNode Class Reference

Base class for most objects within the FTK. More...

#include <SIBCNode.h>

Inheritance diagram for CSIBCNode:

CdotXSIParam CdotXSITemplate CSLTemplate CSLAction CSLActionClip CSLAmbience CSLAngle CSLBaseFCurve CSLBaseMaterial CSLBaseShape CSLCluster CSLConstraint CSLCoordinateSystem CSLCustomPSet CSLEnvelope CSLEnvelopeList CSLExtrapolation CSLFileInfo CSLFog CSLFXOperator CSLFXTree CSLGlobalMaterial CSLIKResolutionPlane CSLImage CSLImageClip CSLImageData CSLImageFX CSLImageFX2 CSLImageLibrary CSLLightInfo CSLMaterialLibrary CSLMixer CSLModel CSLNurbsProjection CSLNurbsTrim CSLPolygonList CSLPrimitive CSLSceneInfo CSLShaderInstanceData CSLShapeAnimation CSLStaticValue CSLTexture2D CSLTimeControl CSLTrack CSLTransform CSLTriangleList CSLTriangleStrip CSLTriangleStripList CSLUserData CSLUserDataBlob CSLUserDataList CSLVisibility CSLXSIBasePose CSLXSICameraFocalLength CSLXSIClipToParent CSLXSIClusterInfo CSLXSICustomParamInfo CSLXSIIndexList CSLXSILimit CSLXSILookat CSLXSIMaterialInfo CSLXSIMatrix CSLXSIPolymatricks CSLXSIRotate CSLXSIScale CSLXSIShader CSLXSIShaderMultiPortConnection CSLXSIShape CSLXSIShapeAnimation CSLXSIShapeReference CSLXSIShear CSLXSISubComponentAttributeList CSLXSISubComponentList CSLXSITextureLayer CSLXSITextureLayerPort CSLXSITransform CSLXSITranslate CSLXSIUserKeyword List of all members.

Public Member Functions

  CSIBCNode ()
virtual void  Dump ()
virtual SI_UInt  UsedMemory ()
virtual SI_UInt  AllocatedMemory ()
virtual SI_UInt  LocalSize ()
CSIBCString Name ()
SI_UInt  GetFlags ()
SI_Void  SetFlags (SI_UInt in_lFlags)
CSIBCArray< CSIBCUserData * > &  UserDataList ()
CSIBCUserData FindUserData (SI_Char *in_pTag)
CSIBCUserData GetUserData (SI_Int in_iIndex)
SI_Error  AttachUserData (SI_Char *in_pTag, SI_Void *in_pData)
SI_Error  RemoveUserData (SI_Char *in_pTag)
virtual CSIBCNode Duplicate (CSIBCNode *i_pNode)

Detailed Description

Base class for most objects within the FTK.

This class provides a set of methods available to all classes that are derived from it, including memory usage functions, identification functions, and functions dealing with user data, represented by CSIBCUserData objects.


Constructor & Destructor Documentation

CSIBCNode (  ) 

Default constructor. Simply clears all flags for the new node. (See CSIBCNode::SetFlags)


Member Function Documentation

virtual void Dump (  )  [virtual]

Outputs debugging information for the node. This method is over-ridable, but in this base class, it simply outputs the address of the node. Note: although this method is over-ridable, it is generally left to this base implementation.

virtual SI_UInt UsedMemory (  )  [virtual]

Returns how much memory this node uses. This number does not include how much space the object itself requires (see CSIBCNode::LocalSize), only the memory used by its members. This number is distinct from the memory actually allocated by the object (See CSIBCNode::AllocatedMemory).

Returns:
SI_UInt The amount of memory used by this object's members' (in bytes).

virtual SI_UInt AllocatedMemory (  )  [virtual]

Returns how much memory this node has allocated. This number does not include how much space the object itself requires (see CSIBCNode::LocalSize), only the memory allocated by its members. This number is distinct from the memory actually used by the object (See CSIBCNode::UsedMemory).

Returns:
SI_UInt The amount of memory allocated by this object's members' (in bytes)

virtual SI_UInt LocalSize (  )  [virtual]

Returns the size of this object (analogous to the sizeof operator). As such, it does not include any memory dynamically allocated by the members of the class.

CSIBCString& Name (  )  [inline]

Gets the name string for the object.

Returns:
CSIBCString& Reference to the string which holds the name of this node.

SI_UInt GetFlags (  )  [inline]

Get the flags associated with this node.

Returns:
SI_UInt Value indicating which flags are set for this node.

SI_Void SetFlags ( SI_UInt  in_lFlags  )  [inline]

Sets the flags associated with this node. Note that this function unsets all flags, thus if flags need to be persisted, they should first be obtained from SIBCNode::GetFlags, and bit-wise OR'd with the new flags, and then sent to this function.

Parameters:
in_lFlags  The new flag state for this node.

CSIBCArray< CSIBCUserData* >& UserDataList (  )  [inline]

Returns a CSIBCArray of the user data attached to this node.

Returns:
CSIBCArray<CSIBCUserData *>& Reference to the array of user data attached to this node.

CSIBCUserData* FindUserData ( SI_Char *  in_pTag  ) 

Finds the first instance of CSIBCUserData attached to this node with the tag name given by in_pTag.

Parameters:
in_pTag  The tag name to search attached user data objects for.
Returns:
CSIBCUserData* Pointer to the first instance of user data attached to this node with tag name in_pTag. Returns NULL if no user data is attached with the tag name.

Reimplemented in CSLUserDataList.

CSIBCUserData* GetUserData ( SI_Int  in_iIndex  ) 

Returns the user data attached at a given index.

Parameters:
in_iIndex  Index of the attached user data object to retrieve. Must be a valid index.
Returns:
CSIBCUserData* Pointer to the user data element at the index given by in_iIndex

SI_Error AttachUserData ( SI_Char *  in_pTag,
SI_Void *  in_pData  
)

Attaches user data to this node. Creates a new CSIBCUserData object, containing

Parameters:
in_pTag  Tag name used to attach the data to the node. Must be unique per node.
in_pData  Pointer to the data to attach (may be of any type, cast to SI_Void *).
Returns:
SI_Error Error code indicating success or failure of function.
returns: SI_SUCCESS - The user data was attached properly

SI_Error RemoveUserData ( SI_Char *  in_pTag  ) 

Finds the first instance of CSIBCUserData attached to this node with the tag name given by in_pTag and remove it.

Parameters:
in_pTag  The tag name of the user data object to remove.
Returns:
SI_Error Error code indicating success or failure of function.

virtual CSIBCNode* Duplicate ( CSIBCNode i_pNode  )  [virtual]

Creates a duplicate node containing the information contained in this node. This method is intended to be over-ridden by subclasses, because the duplication process will always be derived class specific. If i_pNode is NULL, a new node is created to duplicate this node's information, otherwise, the data contained within i_pNode is overwritten by the information from this node.

Parameters:
i_pNode  Node to put the duplicate information into. If NULL, a new node is created.
Returns:
CSIBCNode* Pointer to the node containing the duplicated information


The documentation for this class was generated from the following file: