Archon::X3D::CustomFieldNode Struct Reference

The base of all nodes that can contain custom fields. More...

#include <archon/x3d/server/custom_field.H>

Inheritance diagram for Archon::X3D::CustomFieldNode:

Inheritance graph
[legend]
Collaboration diagram for Archon::X3D::CustomFieldNode:

Collaboration graph
[legend]
List of all members.

Public Member Functions

bool addCustomField (Ref< CustomFieldBase >) throw (RealizedException)
unsigned getNumberOfCustomFields () const
 The 'customFields' variable is constant after realization of the node.
Ref< CustomFieldBasegetCustomField (unsigned index) const
Ref< CustomFieldBasegetCustomFieldNoLock (unsigned index) const
 Must only be called while holding the scenegraph read lock.

Protected Member Functions

 CustomFieldNode ()
virtual void handleEvent (int fieldIndex, Time timestamp)=0
 Must be called with a scenegraph write lock, and never with a lock on any node.

Protected Attributes

vector< Ref< CustomFieldBase > > customFields

Detailed Description

The base of all nodes that can contain custom fields.

That is, fields which are user specified and thus not a part of the static node type. An obvious example is the Script node.

We should think of an unrealized CustomFieldNode as one where we can still add new custom fields. Likewise we should think of a realized CustomFieldNode as one where adding a new custom field is an illegal operation.

Definition at line 100 of file custom_field.H.


Member Function Documentation

bool Archon::X3D::CustomFieldNode::addCustomField Ref< CustomFieldBase  )  throw (RealizedException)
 

May not be called for a realized node.

Definition at line 38 of file custom_field.C.

References Archon::SaiTestApps::Filebrowser::mutex.

unsigned Archon::X3D::CustomFieldNode::getNumberOfCustomFields  )  const [inline]
 

The 'customFields' variable is constant after realization of the node.

Therefor you can call this method and 'getCustomField' without previously aquiring the scenegraph mutex if you know that the node is realized.

Definition at line 114 of file custom_field.H.

References customFields, and Archon::X3D::NodeBase::mutex.

Referenced by Archon::X3D::ECMA::Engine::Engine().

virtual void Archon::X3D::CustomFieldNode::handleEvent int  fieldIndex,
Time  timestamp
[protected, pure virtual]
 

Must be called with a scenegraph write lock, and never with a lock on any node.

Also, this method may never be called for an un-realized node.

Referenced by Archon::X3D::NodeSequenceCustomField< C >::add(), Archon::X3D::SimpleSeqCustomField< T >::add(), Archon::X3D::NodeSequenceCustomField< C >::inject(), Archon::X3D::NodeCustomField< C >::inject(), Archon::X3D::NodeSequenceCustomField< C >::remove(), Archon::X3D::SimpleSeqCustomField< T >::remove(), Archon::X3D::NodeSequenceCustomField< C >::set(), Archon::X3D::NodeCustomField< C >::set(), Archon::X3D::SimpleSeqCustomField< T >::set(), Archon::X3D::SimpleCustomField< T >::set(), Archon::X3D::NodeSequenceCustomField< C >::setAt(), and Archon::X3D::SimpleSeqCustomField< T >::setAt().


The documentation for this struct was generated from the following files:
Generated on Sun Jul 30 22:58:51 2006 for Archon by  doxygen 1.4.4