#include <DEP_MicroNode.h>

Public Types | |
| typedef boost::function2< void, DEP_MicroNode &, DEP_MicroNode & > | Visitor |
| typedef bool(DEP_MicroNode::* | GetFlag )() const |
| typedef void(DEP_MicroNode::* | SetFlag )(bool flag) |
Public Member Functions | |
| DEP_MicroNode () | |
| virtual | ~DEP_MicroNode () |
| virtual const char * | className () const |
| virtual void | getInputs (DEP_MicroNodeList &inputs) const |
| virtual void | clearInputs () |
| virtual void | getOutputs (DEP_MicroNodeList &outputs) const |
| virtual void | update (fpreal t) |
| virtual bool | requiresUpdate (fpreal t) const |
| void | propagateDirty (Visitor client_visit, bool only_outputs=false) |
| bool | markVisitPass (int pass) |
| int | lastVisitPass () const |
| virtual exint | getMemUsage (bool include_this) const |
| Obtain approximate memory usage. | |
| virtual void | dump (std::ostream &os, const char *prefix=0, int indent_level=0) const |
| Dump contents to output stream, strictly for debugging purposes. | |
| void | dumpAsDOT (std::ostream &os, const char *prefix=0, int indent_level=0) const |
| Dump the contents is a manner more suitable for DOT. | |
| void | addExplicitInput (DEP_MicroNode &inp) |
| Methods for manipulating explicit edges. | |
| void | getExplicitInputs (DEP_MicroNodeList &inputs) const |
| Get list of all non-null explicit inputs. | |
| int | getNumExplicitInputs () const |
| Get the number of non-null inputs. | |
| int | getNumExplicitOutputs () const |
| Get the number of non-null outputs. | |
| bool | isDirty () const |
| Flag accessors. | |
| void | setDirty (bool flag, bool allow_clear=true) |
| Flag accessors. | |
| bool | isTimeDependent () const |
| Flag accessors. | |
| void | setTimeDependent (bool time_dependent) |
| Flag accessors. | |
| bool | isTimeInterested () const |
| Flag accessors. | |
| void | setTimeInterested (bool time_interested) |
| Flag accessors. | |
Static Public Member Functions | |
| static bool | canClearDependencies () |
| Global control whether dependencies can be cleared. | |
Protected Member Functions | |
| virtual bool | isEvaluating () const |
| virtual void | evaluateExports () |
| virtual bool | isExporting () const |
Friends | |
| class | dep_Visitor |
| class | DEP_KeepDependenciesScope |
DEP_MicroNode's form a dependency graph that are connected both implicitly and explicitly. The base class maintains the explicit edges while subclasses maintain the implicit edges by overriding the getInputs()/getOutputs() methods.
Definition at line 50 of file DEP_MicroNode.h.
| typedef bool(DEP_MicroNode::* DEP_MicroNode::GetFlag)() const |
Definition at line 157 of file DEP_MicroNode.h.
| typedef void(DEP_MicroNode::* DEP_MicroNode::SetFlag)(bool flag) |
Definition at line 158 of file DEP_MicroNode.h.
| typedef boost::function2< void, DEP_MicroNode & , DEP_MicroNode & > DEP_MicroNode::Visitor |
Definition at line 114 of file DEP_MicroNode.h.
| DEP_MicroNode::DEP_MicroNode | ( | ) |
| virtual DEP_MicroNode::~DEP_MicroNode | ( | ) | [virtual] |
| void DEP_MicroNode::addExplicitInput | ( | DEP_MicroNode & | inp | ) |
Methods for manipulating explicit edges.
Add an input that this micronode depends on
| static bool DEP_MicroNode::canClearDependencies | ( | ) | [inline, static] |
| virtual const char* DEP_MicroNode::className | ( | void | ) | const [inline, virtual] |
Reimplemented in OP_DataMicroNode, OP_ParmMicroNode, and PRM_ParmMicroNode.
Definition at line 57 of file DEP_MicroNode.h.
| virtual void DEP_MicroNode::clearInputs | ( | ) | [inline, virtual] |
Clear all inputs, including any state data related to them. Default implementation just calls clearExplicitInputs() and setTimeDependent(false).
Reimplemented in OP_DataMicroNode, and PRM_ParmMicroNode.
Definition at line 67 of file DEP_MicroNode.h.
| virtual void DEP_MicroNode::dump | ( | std::ostream & | os, | |
| const char * | prefix = 0, |
|||
| int | indent_level = 0 | |||
| ) | const [virtual] |
Dump contents to output stream, strictly for debugging purposes.
Reimplemented in OP_DataMicroNode, OP_ParmMicroNode, and PRM_ParmMicroNode.
| void DEP_MicroNode::dumpAsDOT | ( | std::ostream & | os, | |
| const char * | prefix = 0, |
|||
| int | indent_level = 0 | |||
| ) | const |
Dump the contents is a manner more suitable for DOT.
| virtual void DEP_MicroNode::evaluateExports | ( | ) | [inline, protected, virtual] |
evaluateExports() is called after isExporting() is noted to be true during a dirty propagation pass initiated by dirtySubtree().
Reimplemented in OP_DataMicroNode.
Definition at line 204 of file DEP_MicroNode.h.
| void DEP_MicroNode::getExplicitInputs | ( | DEP_MicroNodeList & | inputs | ) | const |
Get list of all non-null explicit inputs.
| virtual void DEP_MicroNode::getInputs | ( | DEP_MicroNodeList & | inputs | ) | const [virtual] |
Get list of all our non-null inputs, both implicit and explicit. The base class returns the list of explicit inputs.
Reimplemented in OP_DataMicroNode.
| virtual exint DEP_MicroNode::getMemUsage | ( | bool | include_this | ) | const [virtual] |
| int DEP_MicroNode::getNumExplicitInputs | ( | ) | const [inline] |
| int DEP_MicroNode::getNumExplicitOutputs | ( | ) | const [inline] |
| virtual void DEP_MicroNode::getOutputs | ( | DEP_MicroNodeList & | outputs | ) | const [virtual] |
Get list of all our non-null outputs, both implicit and explicit. The base class returns the list of explicit outputs.
Reimplemented in OP_DataMicroNode, and OP_ParmMicroNode.
| bool DEP_MicroNode::isDirty | ( | ) | const [inline] |
| virtual bool DEP_MicroNode::isEvaluating | ( | ) | const [inline, protected, virtual] |
These methods are overriden by subclasses to be used by the dirty propagation algorithm. Used to determine if a micronode is currently evaluating. If this returns true, during dirty propagation, it will prevent dependencies from being removed from it.
Reimplemented in OP_DataMicroNode.
Definition at line 199 of file DEP_MicroNode.h.
| virtual bool DEP_MicroNode::isExporting | ( | ) | const [inline, protected, virtual] |
Used to determine if a micronode requires its exports to be evaluated during the propagation pass.
Reimplemented in OP_DataMicroNode.
Definition at line 208 of file DEP_MicroNode.h.
| bool DEP_MicroNode::isTimeDependent | ( | ) | const [inline] |
| bool DEP_MicroNode::isTimeInterested | ( | ) | const [inline] |
| int DEP_MicroNode::lastVisitPass | ( | ) | const [inline] |
Definition at line 140 of file DEP_MicroNode.h.
| bool DEP_MicroNode::markVisitPass | ( | int | pass | ) | [inline] |
Mark this micronode as having seen the given global dirty counter. Returns false if we've already seen it.
Definition at line 132 of file DEP_MicroNode.h.
| void DEP_MicroNode::propagateDirty | ( | Visitor | client_visit, | |
| bool | only_outputs = false | |||
| ) |
Mark this micronode and all its dependents as dirty. The global dirty counter will be incremented once for each call to propagateDirty().
| client_visit | Called for each micronode that is dirtied | |
| only_outputs | If true, then *this is ommitted from being dirtied |
| virtual bool DEP_MicroNode::requiresUpdate | ( | fpreal | t | ) | const [inline, virtual] |
requiresUpdate() specifies if the micro-node was dirtied, possibly based on the time t. By default, it returns isDirty() but subclasses override this to handle other conditions that make this micro-node requiring an update.
Reimplemented in OP_DataMicroNode.
Definition at line 87 of file DEP_MicroNode.h.
| void DEP_MicroNode::setDirty | ( | bool | flag, | |
| bool | allow_clear = true | |||
| ) | [inline] |
| void DEP_MicroNode::setTimeDependent | ( | bool | time_dependent | ) | [inline] |
| void DEP_MicroNode::setTimeInterested | ( | bool | time_interested | ) | [inline] |
| virtual void DEP_MicroNode::update | ( | fpreal | t | ) | [inline, virtual] |
update() is used by users of micro-nodes to mark this node as clean at the given time t. By default, it simply marks it as no longer dirty but subclasses override this to do more work.
Reimplemented in OP_DataMicroNode.
Definition at line 80 of file DEP_MicroNode.h.
friend class DEP_KeepDependenciesScope [friend] |
Definition at line 262 of file DEP_MicroNode.h.
friend class dep_Visitor [friend] |
Definition at line 261 of file DEP_MicroNode.h.
1.5.9