|
|
|
|
Documentation |
|
Main Page Namespace List Class Hierarchy Alphabetical List Compound List File List Namespace Members Compound Members File Members Related Pages Search
NL3D::ITrav Class ReferenceA base Traversal.
More...
#include <mot.h>
Inheritance diagram for NL3D::ITrav
[legend]Collaboration diagram for NL3D::ITrav:
[legend]List of all members.
Detailed Description
A base Traversal.
A traversal represent a functionality, something which is be performed on a graph of model. Since, we may have differents graph of models, dependent on the traversal, a traversal maintain rather a graph of observers. But this is invisible for the user, since he calls link() methods with models.
A traversal provide:
DERIVERS RULES:
No traverse() method is provided. The deriver may use their own function. -
See also:
-
CMOT IModel IObs
-
Author(s):
-
Lionel Berenguier , Nevrax France
-
Date:
-
2000
Definition at line 595 of file mot.h.
Constructor & Destructor Documentation
NL3D::ITrav::ITrav (
|
) [inline]
|
|
|
Constructor. Root Must be created/linked by User via setRoot().
Definition at line 602 of file mot.h. |
NL3D::ITrav::~ITrav (
|
) [inline, virtual]
|
|
|
Destructor. ~ITrav() doesn't delete Root. Root Must be destructed by user.
Definition at line 604 of file mot.h. |
Member Function Documentation
void NL3D::ITrav::copyChildren (
|
IModel * parentFrom,
|
|
IModel * parentTo ) const
|
|
|
make the children of parentFrom become the children of parentTo too (may works like moveChildren if children are TreeNode).
Definition at line 370 of file mot.cpp. |
IObs * NL3D::ITrav::createDefaultObs (
|
) const [pure virtual]
|
|
|
Return the first child of the Model for this traversal. NULL returned if not found.
Definition at line 391 of file mot.cpp. |
|
Return the first Parent of the Model for this traversal. NULL returned if not found.
Definition at line 410 of file mot.cpp. |
sint NL3D::ITrav::getNumChildren (
|
IModel * m ) const
|
|
|
Get the number of children of the model for this traversal.
Definition at line 385 of file mot.cpp. |
sint NL3D::ITrav::getNumParents (
|
IModel * m ) const
|
|
|
Get the number of Parents of the model for this traversal.
Definition at line 404 of file mot.cpp. |
IModel * NL3D::ITrav::getRoot (
|
) const
|
|
|
Get the root of the traversal (NULL if not defined).
Definition at line 290 of file mot.cpp. |
|
Link 2 models via their IObs for this traversal.
m2 becomes a child of m1. If m1==NULL, m2 will be linked to the Root of this traversal (or do nothing if this one is NULL). if m2 was already a son of m1, no-op.
Definition at line 299 of file mot.cpp. |
void NL3D::ITrav::moveChildren (
|
IModel * parentFrom,
|
|
IModel * parentTo ) const
|
|
|
make the children of parentFrom unlinked, and become the children of parentTo.
Definition at line 356 of file mot.cpp. |
void NL3D::ITrav::setRoot (
|
IModel * root )
|
|
|
Specify a root Model for this traversal (via his IObs).
The model must be created with a valid/final CMOT. CMOT::createModel() will don't link the model if a traversal in the CMOT object has not specified a root.
ITrav::link()(NULL, ...) will assert, if no root defined.
You may specify a NULL root (this may lead to a disabled traversal).
Definition at line 282 of file mot.cpp. |
|
Unlink 2 models via their IObs for this traversal.
If m1==NULL, m2 will be unlinked from the Root of this traversal (or do nothing if this one is NULL). if m2 was not a son of m1, no-op.
Definition at line 327 of file mot.cpp. |
Member Data Documentation
The documentation for this class was generated from the following files:
|
|