#include <ForEachLoop.hxx>


Public Member Functions | |
| ForEachLoopGen (const std::string &name, TypeCode *typeOfDataSplitted, std::unique_ptr< NbBranchesAbstract > &&branchManager) | |
| ForEachLoopGen (const ForEachLoopGen &other, ComposedNode *father, bool editionOnly) | |
| ~ForEachLoopGen () | |
| void | init (bool start=true) |
| void | exUpdateState () |
| Update the node state. More... | |
| void | exUpdateProgress () |
| void | getReadyTasks (std::vector< Task * > &tasks) |
| int | getNumberOfInputPorts () const |
| void | checkNoCyclePassingThrough (Node *node) |
| void | selectRunnableTasks (std::vector< Task * > &tasks) |
| unsigned | getExecCurrentId () const |
| std::list< InputPort * > | getSetOfInputPort () const |
| std::list< InputPort * > | getLocalInputPorts () const |
| redefined on derived class of ComposedNode. by default a ComposedNode has no port by itself More... | |
| InputPort * | edGetSeqOfSamplesPort () |
| InputPort * | getInputPort (const std::string &name) const |
| Get an input port given its name. More... | |
| OutPort * | getOutPort (const std::string &name) const |
| OutputPort * | getOutputPort (const std::string &name) const |
| Get an output port given its name. More... | |
| Node * | getChildByShortName (const std::string &name) const |
| std::list< OutputPort * > | getLocalOutputPorts () const |
| redefined on derived class of ComposedNode. by default a ComposedNode has no port by itself More... | |
| void | writeDot (std::ostream &os) const |
| Dump the node state to a stream. More... | |
| virtual std::string | typeName () |
| virtual void | resetState (int level) |
| Reset the state of the node and its children depending on the parameter level. More... | |
| std::string | getProgress () const |
| std::list< ProgressWeight > | getProgressWeight () const |
| Get the progress weight for all elementary nodes. More... | |
| int | getCurrentIndex () const |
| int | getNbOfElementsToBeProcessed () const |
| ForEachLoopPassedData * | getProcessedData () const |
| void | setProcessedData (ForEachLoopPassedData *processedData) |
| std::vector< unsigned int > | getPassedResults (Executor *execut, std::vector< SequenceAny * > &outputs, std::vector< std::string > &nameOfOutputs) const |
| void | assignPassedResults (const std::vector< unsigned int > &passedIds, const std::vector< SequenceAny * > &passedOutputs, const std::vector< std::string > &nameOfOutputs) |
| const TypeCode * | getOutputPortType (const std::string &portName) const |
| void | cleanDynGraph () override |
Public Member Functions inherited from YACS::ENGINE::DynParaLoop | |
| Node * | edRemoveNode () |
| Node * | edRemoveInitNode () |
| Node * | edRemoveFinalizeNode () |
| Node * | edSetNode (Node *DISOWNnode) |
| Node * | edSetInitNode (Node *DISOWNnode) |
| Node * | edSetFinalizeNode (Node *DISOWNnode) |
| virtual bool | edAddDFLink (OutPort *start, InPort *end) |
| Connect an OutPort to an InPort and add control link if necessary. More... | |
| InputPort * | edGetNbOfBranchesPort () |
| int | getNumberOfOutputPorts () const |
| unsigned | getNumberOfEltsConsumed () const |
| int | getBranchIDOfNode (Node *node) const |
| std::list< OutputPort * > | getSetOfOutputPort () const |
| OutputPort * | edGetSamplePort () |
| bool | isPlacementPredictableB4Run () const |
| For the moment false is returned : impovement about it coming soon. More... | |
| void | edRemoveChild (Node *node) |
| Remove a child node. More... | |
| bool | isLoop () const override |
| virtual bool | edAddChild (Node *DISOWNnode) |
| std::list< Node * > | edGetDirectDescendants () const |
| unsigned | getNumberOfBranchesCreatedDyn () const |
| Node * | getChildByNameExec (const std::string &name, unsigned id) const |
| std::vector< Node * > | getNodes () const |
| ComplexWeight * | getWeight () |
| void | setWeight (double loopWeight) |
| void | getWeightRegardingDPL (ComplexWeight *weight) |
| bool | isMultiplicitySpecified (unsigned &value) const |
| void | forceMultiplicity (unsigned value) |
| virtual void | checkBasicConsistency () const |
| virtual std::string | getErrorReport () |
| returns a string that contains an error report if the node is in error More... | |
| void | accept (Visitor *visitor) |
| Node * | getInitNode () |
| Node * | getExecNode () |
| Node * | getFinalizeNode () |
| int | getMaxLevelOfParallelism () const |
| void | partitionRegardingDPL (const PartDefinition *pd, std::map< ComposedNode *, YACS::BASES::AutoRefCnt< PartDefinition > > &zeMap) |
Public Member Functions inherited from YACS::ENGINE::ComposedNode | |
| virtual | ~ComposedNode () |
| bool | isFinished () |
| std::string | getName () const |
| std::string | getTaskName (Task *task) const |
| DeploymentTree | getDeploymentTree () const |
| Essentially for test. Use checkDeploymentTree instead to be sure that returned DeploymentTree is consistent. More... | |
| DeploymentTree | checkDeploymentTree (bool deep) const |
| Perform check of deployment consistency of the current graph. More... | |
| std::vector< Task * > | getNextTasks (bool &isMore) |
| void | notifyFrom (const Task *sender, YACS::Event event, const Executor *execInst) |
| Notify the node a task has emitted an event. More... | |
| bool | edAddLink (OutPort *start, InPort *end) |
| Add a dataflow link between two data ports. More... | |
| bool | edAddLink (OutGate *start, InGate *end) |
| Add a controlflow link between two control ports. More... | |
| bool | edAddCFLink (Node *nodeS, Node *nodeE) |
| Add a controlflow link between two nodes. More... | |
| void | edRemoveCFLink (Node *nodeS, Node *nodeE) |
| Remove a controlflow link. More... | |
| void | edRemoveLink (OutPort *start, InPort *end) |
| Remove a dataflow link. More... | |
| void | edRemoveLink (OutGate *start, InGate *end) |
| Remove a controlflow link. More... | |
| virtual bool | isRepeatedUnpredictablySeveralTimes () const |
| virtual void | removeRecursivelyRedundantCL () |
| std::list< ElementaryNode * > | getRecursiveConstituents () const |
| std::list< Node * > | getAllRecursiveNodes () |
| Get all children nodes elementary and composed including this node. More... | |
| virtual std::list< Node * > | getAllRecursiveConstituents () |
| Idem getAllRecursiveNodes, but this node is NOT included. More... | |
| std::string | getInPortName (const InPort *) const |
| Get the input port name. More... | |
| std::string | getOutPortName (const OutPort *) const |
| std::set< OutPort * > | getAllOutPortsLeavingCurrentScope () const |
| List all output ports of children nodes that are linked to out of scope input ports. More... | |
| std::set< InPort * > | getAllInPortsComingFromOutsideOfCurrentScope () const |
| List all input ports that are linked to out of scope ports. More... | |
| std::list< InputDataStreamPort * > | getSetOfInputDataStreamPort () const |
| std::list< OutputDataStreamPort * > | getSetOfOutputDataStreamPort () const |
| InputDataStreamPort * | getInputDataStreamPort (const std::string &name) const |
| OutputDataStreamPort * | getOutputDataStreamPort (const std::string &name) const |
| std::vector< std::pair< OutPort *, InPort * > > | getSetOfInternalLinks () const |
| virtual std::vector< std::pair< OutPort *, InPort * > > | getSetOfLinksLeavingCurrentScope () const |
| void | checkConsistency (LinkInfo &info) const |
| virtual std::vector< std::pair< InPort *, OutPort * > > | getSetOfLinksComingInCurrentScope () const |
| virtual void | edUpdateState () |
| update the status of the node More... | |
| ComposedNode * | getRootNode () const |
| bool | isNodeAlreadyAggregated (const Node *node) const |
| Check that Node 'node' is already a direct son of this. More... | |
| virtual bool | isNameAlreadyUsed (const std::string &name) const |
| Node * | isInMyDescendance (Node *nodeToTest) const |
| Returns the parent of a node that is the direct child of this node. More... | |
| std::string | getChildName (const Node *node) const |
| virtual std::string | getMyQualifiedName (const Node *directSon) const |
| Node * | getChildByName (const std::string &name) const |
| void | loaded () |
| void | connected () |
| virtual void | cleanNodes () |
| Clean the composed node in case of not clean exit. More... | |
| void | setProperty (const std::string &name, const std::string &value) override |
| std::string | getProperty (const std::string &name) override |
Public Member Functions inherited from YACS::ENGINE::Node | |
| virtual | ~Node () |
| Node * | clone (ComposedNode *father, bool editionOnly=true) const |
| This method MUST NEVER BE VIRTUAL More... | |
| Node * | cloneWithoutCompAndContDeepCpy (ComposedNode *father, bool editionOnly=true) const |
| This method MUST NEVER BE VIRTUAL More... | |
| void | setState (YACS::StatesForNode theState) |
| Sets the given state for node. More... | |
| virtual YACS::StatesForNode | getState () const |
| virtual YACS::StatesForNode | getEffectiveState () const |
| Return the node state in the context of its father. More... | |
| virtual YACS::StatesForNode | getEffectiveState (const Node *) const |
| Return the effective state of a node in the context of this one (its father) More... | |
| std::string | getColorState (YACS::StatesForNode state) const |
| Return the color associated to a state. More... | |
| InGate * | getInGate () |
| OutGate * | getOutGate () |
| const std::string & | getName () const |
| void | setName (const std::string &name) |
| Change the name of the node. More... | |
| ComposedNode * | getFather () const |
| const std::string | getId () const |
| bool | exIsControlReady () const |
| std::list< Node * > | getOutNodes () const |
| void | writeDotInFile (const std::string &fileName) const |
| virtual void | exFailedState () |
| Notify this node that its execution has failed. More... | |
| virtual void | exDisabledState () |
| Notify this node that it has been disabled. More... | |
| std::list< InPort * > | getSetOfInPort () const |
| std::list< OutPort * > | getSetOfOutPort () const |
| virtual std::set< InputPort * > | edGetSetOfUnitializedInputPort () const |
| Becomes deprecated soon. Replaced by ComposedNode::CheckConsistency. More... | |
| virtual bool | edAreAllInputPortInitialized () const |
| Becomes deprecated soon. Replaced by ComposedNode::CheckConsistency. More... | |
| InPort * | getInPort (const std::string &name) const |
| InPropertyPort * | getInPropertyPort () const |
| std::list< ComposedNode * > | getAllAscendanceOf (ComposedNode *levelToStop=0) const |
| bool | operator> (const Node &other) const |
| bool | operator< (const Node &other) const |
| std::string | getImplementation () const |
| DynParaLoop * | getClosestDPLAmongAncestors () const |
| std::map< std::string, std::string > | getProperties () |
| std::map< std::string, std::string > | getPropertyMap () |
| virtual void | setProperties (std::map< std::string, std::string > properties) |
| virtual Proc * | getProc () |
| virtual const Proc * | getProc () const |
| std::string | getQualifiedName () const |
| same as Node::getName() in most cases, but differs for children of switch More... | |
| int | getNumId () |
| return node instance identifiant, unique for each node instance More... | |
| std::vector< std::pair< std::string, int > > | getDPLScopeInfo (ComposedNode *gfn) |
| virtual void | applyDPLScope (ComposedNode *gfn) |
| virtual void | sendEvent (const std::string &event) |
| emit notification to all observers registered with the dispatcher More... | |
| virtual void | sendEvent2 (const std::string &event, void *something) |
| emit notification to all observers registered with the dispatcher More... | |
| virtual std::string | getErrorDetails () const |
| virtual void | setErrorDetails (const std::string &error) |
| virtual void | modified () |
| Sets Node in modified state and its father if it exists. More... | |
| virtual int | isModified () |
| virtual int | isValid () |
| indicates if the node is valid (returns 1) or not (returns 0) More... | |
| virtual std::string | getContainerLog () |
| returns a string that contains the name of the container log file if it exists More... | |
| virtual void | ensureLoading () |
| Put this node into TOLOAD state when possible. More... | |
| virtual void | getCoupledNodes (std::set< Task * > &coupledNodes) |
Public Member Functions inherited from YACS::ENGINE::Scheduler | |
| virtual | ~Scheduler () |
Static Public Member Functions | |
| static int | getFEDeltaBetween (OutPort *start, InPort *end) |
| static void | InterceptorizeNameOfPort (std::string &portName) |
Static Public Member Functions inherited from YACS::ENGINE::ComposedNode | |
| static ComposedNode * | getLowestCommonAncestor (Node *node1, Node *node2) |
| Retrieves the lowest common ancestor of 2 nodes. More... | |
| static std::string | getLowestCommonAncestorStr (const std::string &node1, const std::string &node2) |
Static Public Member Functions inherited from YACS::ENGINE::Node | |
| static std::string | getStateName (YACS::StatesForNode state) |
| Return the name of a state. More... | |
| static void | checkValidityOfNodeName (const std::string &name) |
Static Public Attributes | |
| static const char | NAME_OF_SPLITTERNODE [] ="splitter" |
| static const char | INTERCEPTOR_STR [] ="_interceptor" |
Static Public Attributes inherited from YACS::ENGINE::ComposedNode | |
| static const char | SEP_CHAR_BTW_LEVEL [] ="." |
Static Public Attributes inherited from YACS::ENGINE::Node | |
| static std::map< int, Node * > | idMap |
Protected Member Functions | |
| void | checkLinkPossibility (OutPort *start, const std::list< ComposedNode * > &pointsOfViewStart, InPort *end, const std::list< ComposedNode * > &pointsOfViewEnd) |
| YACS::Event | updateStateOnFinishedEventFrom (Node *node) |
| Method used to notify the node that a child node has finished. More... | |
| YACS::Event | updateStateForInitNodeOnFinishedEventFrom (Node *node, unsigned int id) |
| YACS::Event | updateStateForWorkNodeOnFinishedEventFrom (Node *node, unsigned int id, bool isNormalFinish) |
| YACS::Event | updateStateForFinalizeNodeOnFinishedEventFrom (Node *node, unsigned int id) |
| YACS::Event | updateStateOnFailedEventFrom (Node *node, const Executor *execInst) |
| Method used to notify the node that a child node has failed. More... | |
| void | buildDelegateOf (std::pair< OutPort *, OutPort * > &port, InPort *finalTarget, const std::list< ComposedNode * > &pointsOfView) |
| void | getDelegateOf (std::pair< OutPort *, OutPort * > &port, InPort *finalTarget, const std::list< ComposedNode * > &pointsOfView) |
| void | releaseDelegateOf (OutPort *portDwn, OutPort *portUp, InPort *finalTarget, const std::list< ComposedNode * > &pointsOfView) |
| void | pushAllSequenceValues () |
| void | createOutputOutOfScopeInterceptors (int branchNb) |
| void | prepareSequenceValues (int sizeOfSamples) |
| OutPort * | getDynOutPortByAbsName (int branchNb, const std::string &name) |
| void | storeOutValsInSeqForOutOfScopeUse (int rank, int branchNb) |
Protected Member Functions inherited from YACS::ENGINE::DynParaLoop | |
| DynParaLoop (const std::string &name, TypeCode *typeOfDataSplitted, std::unique_ptr< NbBranchesAbstract > &&branchManager) | |
| virtual | ~DynParaLoop () |
| DynParaLoop (const DynParaLoop &other, ComposedNode *father, bool editionOnly) | |
| void | buildDelegateOf (InPort *&port, OutPort *initialStart, const std::list< ComposedNode * > &pointsOfView) |
| void | checkCFLinks (const std::list< OutPort * > &starts, InputPort *end, unsigned char &alreadyFed, bool direction, LinkInfo &info) const |
| check control flow links More... | |
| void | checkControlDependancy (OutPort *start, InPort *end, bool cross, std::map< ComposedNode *, std::list< OutPort * >, SortHierarc > &fw, std::vector< OutPort * > &fwCross, std::map< ComposedNode *, std::list< OutPort * >, SortHierarc > &bw, LinkInfo &info) const |
| void | prepareInputsFromOutOfScope (int branchNb) |
| void | putValueOnBranch (Any *val, unsigned branchId, bool first) |
| TypeOfNode | getIdentityOfNotifyerNode (const Node *node, unsigned &id) |
| InputPort * | getDynInputPortByAbsName (int branchNb, const std::string &name, bool initNodeAdmitted) |
| virtual void | forwardExecStateToOriginalBody (Node *execNode) |
| std::vector< Node * > | cloneAndPlaceNodesCoherently (const std::vector< Node * > &origNodes) |
| Clone nodes and make their placement consistent with the placement of the original ones. More... | |
| Node * | checkConsistencyAndSetNode (Node *&nodeToReplace, Node *DISOWNnode) |
| This method is used to factorize methods edSetNode, edSetInitNode and edSetFinalizeNode. More... | |
| Node * | removeNode (Node *&nodeToRemove) |
| This method is used to factorize methods edRemoveNode, edRemoveInitNode and edRemoveFinalizeNode. More... | |
| virtual void | shutdown (int level) |
| Stop all pending activities of the composed node. More... | |
Protected Member Functions inherited from YACS::ENGINE::ComposedNode | |
| ComposedNode (const std::string &name) | |
| ComposedNode (const ComposedNode &other, ComposedNode *father) | |
| void | performDuplicationOfPlacement (const Node &other) |
| performs a duplication of placement using clone method of containers and components. clone behaviour is driven by attachOnCloning attribute. More... | |
| void | performShallowDuplicationOfPlacement (const Node &other) |
| performs a also duplication of placement but here containers and components are not copied at all whatever the value of attachedOnCloning. More... | |
| void | edDisconnectAllLinksWithMe () |
| YACS::Event | updateStateFrom (Node *node, YACS::Event event, const Executor *execInst) |
| Update node state on receiving event from a node. More... | |
| virtual YACS::Event | updateStateOnStartEventFrom (Node *node) |
| Method used to notify the node that a child node has started. More... | |
| virtual void | getDelegateOf (InPort *&port, OutPort *initialStart, const std::list< ComposedNode * > &pointsOfView) |
| virtual void | releaseDelegateOf (InPort *&port, OutPort *initialStart, const std::list< ComposedNode * > &pointsOfView) |
| void | checkInMyDescendance (Node *nodeToTest) const |
| Check if a node is in the descendance of this node. More... | |
| template<class PORT > | |
| std::string | getPortName (const PORT *port) const |
| void | checkNoCrossHierachyWith (Node *node) const |
| virtual void | performCFComputations (LinkInfo &info) const |
| perform recursively all CF computations. More... | |
| virtual void | destructCFComputations (LinkInfo &info) const |
| destroy recursively all results of initial computations. More... | |
| Node * | getLowestNodeDealingAll (const std::list< OutPort * > &ports) const |
| void | checkLinksCoherenceRegardingControl (const std::vector< OutPort * > &starts, InputPort *end, LinkInfo &info) const |
| void | solveObviousOrDelegateCFLinks (const std::list< OutPort * > &starts, InputPort *end, unsigned char &alreadyFed, bool direction, LinkInfo &info) const |
Protected Member Functions inherited from YACS::ENGINE::Node | |
| Node (const std::string &name) | |
| Node (const Node &other, ComposedNode *father) | |
| virtual Node * | simpleClone (ComposedNode *father, bool editionOnly=true) const =0 |
| virtual void | exForwardFailed () |
| virtual void | exForwardFinished () |
Static Protected Attributes | |
| static const int | NOT_RUNNING_BRANCH_ID =-1 |
Static Protected Attributes inherited from YACS::ENGINE::DynParaLoop | |
| static const char | NAME_OF_SPLITTED_SEQ_OUT [] = "evalSamples" |
| static const char | OLD_NAME_OF_SPLITTED_SEQ_OUT [] = "SmplPrt" |
Static Protected Attributes inherited from YACS::ENGINE::ComposedNode | |
| static const unsigned char | FED_ST = 2 |
| static const unsigned char | FREE_ST = 0 |
| static const unsigned char | FED_DS_ST = 1 |
Static Protected Attributes inherited from YACS::ENGINE::Node | |
| static const char | SEP_CHAR_IN_PORT [] ="." |
| static int | _total = 0 |
Private Member Functions | |
| int | getFinishedId () |
Friends | |
| class | SplitterNode |
| class | FakeNodeForForEachLoop |
Additional Inherited Members | |
Public Attributes inherited from YACS::ENGINE::Node | |
| YACS::Colour | _colour |
Protected Types inherited from YACS::ENGINE::DynParaLoop | |
| enum | TypeOfNode { INIT_NODE = 5 , WORK_NODE = 6 , FINALIZE_NODE = 7 } |
Static Protected Member Functions inherited from YACS::ENGINE::ComposedNode | |
| static bool | splitNamesBySep (const std::string &globalName, const char separator[], std::string &firstPart, std::string &lastPart, bool priority) |
| Splits name globalName in 2 parts using separator. More... | |
Static Protected Member Functions inherited from YACS::ENGINE::Node | |
| static void | checkValidityOfPortName (const std::string &name) |
| static ComposedNode * | checkHavingCommonFather (Node *node1, Node *node2) |
Definition at line 153 of file ForEachLoop.hxx.
| ForEachLoopGen::ForEachLoopGen | ( | const std::string & | name, |
| TypeCode * | typeOfDataSplitted, | ||
| std::unique_ptr< NbBranchesAbstract > && | branchManager | ||
| ) |
Definition at line 469 of file ForEachLoop.cxx.
| ForEachLoopGen::ForEachLoopGen | ( | const ForEachLoopGen & | other, |
| ComposedNode * | father, | ||
| bool | editionOnly | ||
| ) |
Definition at line 476 of file ForEachLoop.cxx.
References _intecptrsForOutGoingPorts, _outGoingPorts, YACS::ENGINE::AnySplitOutputPort::addRepr(), getOutPort(), YACS::ENGINE::ComposedNode::getOutPortName(), yacsorb.CORBAEngineTest::i, and YACS::ENGINE::InterceptorInputPort::setRepr().
| ForEachLoopGen::~ForEachLoopGen | ( | ) |
Definition at line 493 of file ForEachLoop.cxx.
References _intecptrsForOutGoingPorts, _outGoingPorts, _passedData, and cleanDynGraph().
| void ForEachLoopGen::assignPassedResults | ( | const std::vector< unsigned int > & | passedIds, |
| const std::vector< SequenceAny * > & | passedOutputs, | ||
| const std::vector< std::string > & | nameOfOutputs | ||
| ) |
This method is typically useful for post-mortem relaunch to avoid to recompute already passed cases. This method takes in input exactly the parameters retrieved by getPassedResults method.
Definition at line 1209 of file ForEachLoop.cxx.
References YACS::ENGINE::DynParaLoop::_failedCounter, and _passedData.
Referenced by YACS::ENGINE::nodeParser::onEnd().
|
protectedvirtual |
Reimplemented from YACS::ENGINE::DynParaLoop.
Definition at line 918 of file ForEachLoop.cxx.
References _intecptrsForOutGoingPorts, _outGoingPorts, YACS::ENGINE::AnySplitOutputPort::addRepr(), YACS::ENGINE::DynParaLoop::buildDelegateOf(), YACS::ENGINE::RefCounter::decrRef(), YACS::ENGINE::DataPort::edGetType(), getFEDeltaBetween(), YACS::ENGINE::ComposedNode::getPortName(), yacsorb.CORBAEngineTest::i, InterceptorizeNameOfPort(), YACS::ENGINE::OutputPort::NAME, YACS::ENGINE::TypeCode::sequenceTc(), YACS::ENGINE::InterceptorInputPort::setRepr(), and YACS::ENGINE::TypeCode::subContentType().
|
protectedvirtual |
Reimplemented from YACS::ENGINE::DynParaLoop.
Definition at line 1079 of file ForEachLoop.cxx.
References YACS::ENGINE::DynParaLoop::_nbOfBranches, _splitterNode, YACS::ENGINE::DynParaLoop::checkLinkPossibility(), and YACS::ENGINE::Port::getNode().
|
virtual |
Implements YACS::ENGINE::ComposedNode.
Definition at line 677 of file ForEachLoop.cxx.
|
overridevirtual |
Reimplemented from YACS::ENGINE::DynParaLoop.
Definition at line 1015 of file ForEachLoop.cxx.
References _execOutGoingPorts, _execVals, and YACS::ENGINE::DynParaLoop::cleanDynGraph().
Referenced by init(), resetState(), and ~ForEachLoopGen().
|
protected |
Definition at line 1062 of file ForEachLoop.cxx.
References _execOutGoingPorts, _outGoingPorts, YACS::ENGINE::OutPort::addInPort(), DEBTRACE, getDynOutPortByAbsName(), YACS::ENGINE::DataPort::getName(), YACS::ENGINE::ComposedNode::getOutPortName(), and yacsorb.CORBAEngineTest::i.
Referenced by exUpdateState().
|
inline |
Definition at line 189 of file ForEachLoop.hxx.
References YACS::ENGINE::SplitterNode::_dataPortToDispatch.
Referenced by YACS::HMI::EditionForEachLoop::onModifyCollection().
| void ForEachLoopGen::exUpdateProgress | ( | ) |
Definition at line 644 of file ForEachLoop.cxx.
References YACS::ENGINE::Node::sendEvent().
Referenced by init(), updateStateForFinalizeNodeOnFinishedEventFrom(), and updateStateForWorkNodeOnFinishedEventFrom().
|
virtual |
Update the node state.
Called by InGate::exNotifyFromPrecursor
Reimplemented from YACS::ENGINE::Node.
Definition at line 515 of file ForEachLoop.cxx.
References _execCurrentId, YACS::ENGINE::DynParaLoop::_execFinalizeNodes, YACS::ENGINE::DynParaLoop::_execIds, YACS::ENGINE::DynParaLoop::_execInitNodes, YACS::ENGINE::DynParaLoop::_execNodes, _execOutGoingPorts, _execVals, YACS::ENGINE::DynParaLoop::_finalizeNode, YACS::ENGINE::Node::_inGate, YACS::ENGINE::DynParaLoop::_initializingCounter, YACS::ENGINE::DynParaLoop::_initNode, YACS::ENGINE::DynParaLoop::_nbOfBranches, YACS::ENGINE::DynParaLoop::_nbOfEltConsumed, YACS::ENGINE::DynParaLoop::_node, _nodeForSpecialCases, _passedData, _splitterNode, YACS::ENGINE::Node::_state, YACS::ACTIVATED, YACS::ENGINE::ForEachLoopPassedData::assignAlreadyDone(), YACS::ENGINE::InPort::canSafelySqueezeMemory(), YACS::ENGINE::ForEachLoopPassedData::checkCompatibilyWithNb(), YACS::ENGINE::ForEachLoopPassedData::checkLevel2(), YACS::ENGINE::DynParaLoop::cloneAndPlaceNodesCoherently(), createOutputOutOfScopeInterceptors(), DEBTRACE, YACS::DISABLED, YACS::DONE, YACS::ERROR, testCppPluginInvokation::ex, YACS::ENGINE::Node::exForwardFailed(), YACS::ENGINE::InGate::exIsReady(), FakeNodeForForEachLoop, YACS::ENGINE::DynParaLoop::forwardExecStateToOriginalBody(), YACS::ENGINE::ComposedNode::getAllInPortsComingFromOutsideOfCurrentScope(), YACS::ENGINE::ComposedNode::getAllOutPortsLeavingCurrentScope(), YACS::ENGINE::ComposedNode::getName(), YACS::ENGINE::SplitterNode::getNumberOfElements(), YACS::ENGINE::ForEachLoopPassedData::getNumberOfEltsAlreadyDone(), yacsorb.CORBAEngineTest::i, INFO_YACSTRACE, YACS::ENGINE::DynParaLoop::prepareInputsFromOutOfScope(), prepareSequenceValues(), YACS::ENGINE::SplitterNode::putSplittedValueOnRankTo(), YACS::ENGINE::InputPort::releaseData(), YACS::ENGINE::Node::setErrorDetails(), YACS::ENGINE::Node::setState(), and YACS::ENGINE::ForEachLoopPassedData::toAbsId().
|
virtual |
Reimplemented from YACS::ENGINE::DynParaLoop.
Definition at line 728 of file ForEachLoop.cxx.
References _splitterNode, YACS::ENGINE::DynParaLoop::getChildByShortName(), and NAME_OF_SPLITTERNODE.
|
inline |
|
protectedvirtual |
Reimplemented from YACS::ENGINE::ComposedNode.
Definition at line 962 of file ForEachLoop.cxx.
References YACS::ENGINE::Node::_name, _outGoingPorts, and YACS::ENGINE::OutputPort::NAME.
|
protected |
Definition at line 1006 of file ForEachLoop.cxx.
References YACS::ENGINE::DynParaLoop::_execNodes, YACS::ENGINE::ComposedNode::getChildByName(), YACS::ENGINE::Node::SEP_CHAR_IN_PORT, and YACS::ENGINE::ComposedNode::splitNamesBySep().
Referenced by createOutputOutOfScopeInterceptors().
|
inline |
Definition at line 186 of file ForEachLoop.hxx.
Definition at line 1216 of file ForEachLoop.cxx.
References YACS::ENGINE::Node::getFather(), YACS::ENGINE::ComposedNode::getLowestCommonAncestor(), and YACS::ENGINE::Port::getNode().
Referenced by buildDelegateOf().
|
private |
Definition at line 1038 of file ForEachLoop.cxx.
References _passedData, _splitterNode, YACS::ENGINE::SplitterNode::getNumberOfElements(), and YACS::ENGINE::ForEachLoopPassedData::getNumberOfElementsToDo().
Referenced by updateStateForWorkNodeOnFinishedEventFrom().
|
virtual |
Get an input port given its name.
Contrary to YACS::ENGINE::ComposedNode::getOutputPort, this method is NOT recursive and so the leaf of type ElementaryNode aggregating this InputPort is directly invoked.
Reimplemented from YACS::ENGINE::DynParaLoop.
Definition at line 700 of file ForEachLoop.cxx.
References YACS::ENGINE::SplitterNode::_dataPortToDispatch, _splitterNode, YACS::ENGINE::DynParaLoop::getInputPort(), and YACS::ENGINE::SplitterNode::NAME_OF_SEQUENCE_INPUT.
Referenced by YACS::ENGINE::portParser::onEnd().
|
virtual |
redefined on derived class of ComposedNode. by default a ComposedNode has no port by itself
Reimplemented from YACS::ENGINE::DynParaLoop.
Definition at line 693 of file ForEachLoop.cxx.
References YACS::ENGINE::SplitterNode::_dataPortToDispatch, _splitterNode, and YACS::ENGINE::DynParaLoop::getLocalInputPorts().
Referenced by YACS::ENGINE::VisitorSalomeSaveState::visitForEachLoop().
|
virtual |
redefined on derived class of ComposedNode. by default a ComposedNode has no port by itself
Reimplemented from YACS::ENGINE::DynParaLoop.
Definition at line 1091 of file ForEachLoop.cxx.
References getOutputPort(), and YACS::ENGINE::DynParaLoop::NAME_OF_SPLITTED_SEQ_OUT.
| int ForEachLoopGen::getNbOfElementsToBeProcessed | ( | ) | const |
Definition at line 1163 of file ForEachLoop.cxx.
References YACS::ENGINE::DynParaLoop::_finalizeNode, YACS::ENGINE::DynParaLoop::_initNode, YACS::ENGINE::DynParaLoop::_nbOfBranches, _splitterNode, and YACS::ENGINE::SplitterNode::getNumberOfElements().
Referenced by getProgress(), and getProgressWeight().
|
virtual |
Reimplemented from YACS::ENGINE::DynParaLoop.
Definition at line 672 of file ForEachLoop.cxx.
References YACS::ENGINE::DynParaLoop::getNumberOfInputPorts().
|
virtual |
Reimplemented from YACS::ENGINE::DynParaLoop.
Definition at line 718 of file ForEachLoop.cxx.
References _outGoingPorts, and YACS::ENGINE::DynParaLoop::getOutPort().
Referenced by ForEachLoopGen().
|
virtual |
Get an output port given its name.
Contrary to YACS::ENGINE::ComposedNode::getInputPort, this method is recursive and go down hierarchy step by step to complete its work.
Reimplemented from YACS::ENGINE::DynParaLoop.
Definition at line 708 of file ForEachLoop.cxx.
References _outGoingPorts, and YACS::ENGINE::DynParaLoop::getOutputPort().
Referenced by getLocalOutputPorts().
| const YACS::ENGINE::TypeCode * ForEachLoopGen::getOutputPortType | ( | const std::string & | portName | ) | const |
| portName | : "interceptorized" name of port. |
Definition at line 1266 of file ForEachLoop.cxx.
References _outGoingPorts, YACS::ENGINE::TypeCode::contentType(), DEBTRACE, and YACS::ENGINE::ComposedNode::getPortName().
Referenced by YACS::ENGINE::nodeParser::onEnd().
| std::vector< unsigned int > ForEachLoopGen::getPassedResults | ( | Executor * | execut, |
| std::vector< SequenceAny * > & | outputs, | ||
| std::vector< std::string > & | nameOfOutputs | ||
| ) | const |
This method allows to retrieve the state of this during execution or after. This method works even if this is NOT complete, or during execution or after a failure in this. The typical usage of this method is to retrieve the results of items that passed successfully to avoid to lose all of them if only one fails. This method has one input execut and 3 outputs.
| [in] | execut | - The single input is for threadsafety reasons because this method can be called safely during the execution of this. |
| [out] | outputs | - For each output ports in this linked with nodes sharing the same father than this the passed results are stored. All of the items in outputs have the same size. |
| [out] | nameOfOutputs | - The array with same size than outputs, that tells for each item in outputs the output port it refers to. |
this->edGetSeqOfSamplesPort() that run successfully. The length of this returned array will be the length of all SequenceAny objects contained in outputs.Definition at line 1186 of file ForEachLoop.cxx.
References _execOutGoingPorts, _execVals, YACS::ENGINE::Executor::getTheMutexForSchedulerUpdate(), and yacsorb.CORBAEngineTest::i.
| ForEachLoopPassedData * ForEachLoopGen::getProcessedData | ( | ) | const |
This method is used to obtain the values already processed by the ForEachLoop. A new ForEachLoopPassedData object is returned. You have to delete it.
Definition at line 1238 of file ForEachLoop.cxx.
References _execOutGoingPorts, _execVals, and yacsorb.CORBAEngineTest::i.
Referenced by YACS::ENGINE::VisitorSalomeSaveState::visitForEachLoop().
|
virtual |
Reimplemented from YACS::ENGINE::ComposedNode.
Definition at line 1128 of file ForEachLoop.cxx.
References _currentIndex, and getNbOfElementsToBeProcessed().
|
virtual |
Get the progress weight for all elementary nodes.
Only elementary nodes have weight. For each node in the loop, the weight done is multiplied by the number of elements done and the weight total by the number total of elements
Reimplemented from YACS::ENGINE::ComposedNode.
Definition at line 1144 of file ForEachLoop.cxx.
References YACS::ENGINE::DynParaLoop::edGetDirectDescendants(), getCurrentIndex(), and getNbOfElementsToBeProcessed().
|
virtual |
Implements YACS::ENGINE::Node.
Definition at line 650 of file ForEachLoop.cxx.
References YACS::ENGINE::DynParaLoop::_execFinalizeNodes, YACS::ENGINE::DynParaLoop::_execInitNodes, YACS::ENGINE::DynParaLoop::_execNodes, YACS::ENGINE::DynParaLoop::_node, _nodeForSpecialCases, YACS::ENGINE::Node::_state, YACS::ACTIVATED, YACS::ENGINE::ElementaryNode::getReadyTasks(), YACS::ENGINE::Node::setState(), and YACS::TOACTIVATE.
|
virtual |
Reimplemented from YACS::ENGINE::DynParaLoop.
Definition at line 686 of file ForEachLoop.cxx.
References YACS::ENGINE::SplitterNode::_dataPortToDispatch, _splitterNode, and YACS::ENGINE::DynParaLoop::getSetOfInputPort().
|
virtual |
initialisation of all input and output ports and gates, for execution
Reimplemented from YACS::ENGINE::DynParaLoop.
Definition at line 503 of file ForEachLoop.cxx.
References _currentIndex, _execCurrentId, _passedData, _splitterNode, cleanDynGraph(), exUpdateProgress(), YACS::ENGINE::ForEachLoopPassedData::init(), YACS::ENGINE::DynParaLoop::init(), and YACS::ENGINE::SplitterNode::init().
|
static |
Definition at line 912 of file ForEachLoop.cxx.
References INTERCEPTOR_STR.
Referenced by buildDelegateOf().
|
protected |
Definition at line 1046 of file ForEachLoop.cxx.
References _execVals, _outGoingPorts, yacsorb.CORBAEngineTest::i, and YACS::ENGINE::SequenceAny::New().
Referenced by exUpdateState().
|
protected |
Definition at line 1054 of file ForEachLoop.cxx.
References _execVals, _outGoingPorts, and yacsorb.CORBAEngineTest::i.
Referenced by YACS::ENGINE::FakeNodeForForEachLoop::execute(), and updateStateForWorkNodeOnFinishedEventFrom().
|
protectedvirtual |
Reimplemented from YACS::ENGINE::ComposedNode.
Definition at line 983 of file ForEachLoop.cxx.
References _intecptrsForOutGoingPorts, _outGoingPorts, YACS::ENGINE::DataPort::getNameOfTypeOfCurrentInstance(), YACS::ENGINE::OutputPort::NAME, and p.
|
virtual |
Reset the state of the node and its children depending on the parameter level.
Reimplemented from YACS::ENGINE::ComposedNode.
Definition at line 1120 of file ForEachLoop.cxx.
References _execCurrentId, cleanDynGraph(), and YACS::ENGINE::ComposedNode::resetState().
|
virtual |
| void ForEachLoopGen::setProcessedData | ( | ForEachLoopPassedData * | processedData | ) |
Definition at line 1256 of file ForEachLoop.cxx.
References _passedData.
|
protected |
Definition at line 1027 of file ForEachLoop.cxx.
References _execOutGoingPorts, _execVals, and yacsorb.CORBAEngineTest::i.
Referenced by updateStateForWorkNodeOnFinishedEventFrom().
|
inlinevirtual |
Reimplemented from YACS::ENGINE::ComposedNode.
Definition at line 196 of file ForEachLoop.hxx.
|
protected |
Definition at line 881 of file ForEachLoop.cxx.
References _currentIndex, YACS::ENGINE::DynParaLoop::_finalizeNode, YACS::ENGINE::DynParaLoop::_unfinishedCounter, DEBTRACE, YACS::DONE, exUpdateProgress(), YACS::FINISH, YACS::NOEVENT, and YACS::ENGINE::Node::setState().
Referenced by updateStateOnFinishedEventFrom().
|
protected |
Definition at line 761 of file ForEachLoop.cxx.
References _currentIndex, YACS::ENGINE::DynParaLoop::_execNodes, YACS::ENGINE::DynParaLoop::_initializingCounter, YACS::ENGINE::DynParaLoop::_initNode, YACS::ENGINE::DynParaLoop::_nbOfEltConsumed, YACS::DONE, YACS::NOEVENT, and YACS::ENGINE::Node::setState().
Referenced by updateStateOnFinishedEventFrom().
|
protected |
| [in] | isNormalFinish | - if true |
Definition at line 775 of file ForEachLoop.cxx.
References _currentIndex, _execCurrentId, YACS::ENGINE::DynParaLoop::_execFinalizeNodes, YACS::ENGINE::DynParaLoop::_execIds, YACS::ENGINE::DynParaLoop::_failedCounter, YACS::ENGINE::DynParaLoop::_finalizeNode, YACS::ENGINE::DynParaLoop::_nbOfEltConsumed, YACS::ENGINE::DynParaLoop::_node, _passedData, _splitterNode, YACS::ENGINE::Node::_state, YACS::ENGINE::DynParaLoop::_unfinishedCounter, YACS::ABORT, YACS::ACTIVATED, DEBTRACE, YACS::DONE, YACS::ERROR, testCppPluginInvokation::ex, YACS::ENGINE::Node::exForwardFailed(), exUpdateProgress(), YACS::ENGINE::Node::exUpdateState(), YACS::FAILED, YACS::FINISH, YACS::ENGINE::ComposedNode::getAllRecursiveConstituents(), getFinishedId(), yacsorb.CORBAEngineTest::i, YACS::ENGINE::Node::init(), YACS::ENGINE::ComposedNode::isFinished(), YACS::NOEVENT, NOT_RUNNING_BRANCH_ID, pushAllSequenceValues(), YACS::ENGINE::SplitterNode::putSplittedValueOnRankTo(), YACS::ENGINE::Node::sendEvent2(), YACS::ENGINE::Node::setState(), storeOutValsInSeqForOutOfScopeUse(), YACS::ENGINE::ForEachLoopPassedData::toAbsId(), and YASSERT.
Referenced by updateStateOnFailedEventFrom(), and updateStateOnFinishedEventFrom().
|
protectedvirtual |
Method used to notify the node that a child node has failed.
Update the current state and return the change state
| node | : the child node that has failed |
Reimplemented from YACS::ENGINE::DynParaLoop.
Definition at line 898 of file ForEachLoop.cxx.
References YACS::ENGINE::DynParaLoop::_failedCounter, YACS::ENGINE::DynParaLoop::getIdentityOfNotifyerNode(), YACS::ENGINE::Executor::getKeepGoingProperty(), updateStateForWorkNodeOnFinishedEventFrom(), YACS::ENGINE::DynParaLoop::updateStateOnFailedEventFrom(), and YACS::ENGINE::DynParaLoop::WORK_NODE.
|
protectedvirtual |
Method used to notify the node that a child node has finished.
Update the current state and return the change state
| node | : the child node that has finished |
Implements YACS::ENGINE::ComposedNode.
Definition at line 743 of file ForEachLoop.cxx.
References DEBTRACE, YACS::ENGINE::DynParaLoop::FINALIZE_NODE, YACS::ENGINE::DynParaLoop::getIdentityOfNotifyerNode(), YACS::ENGINE::Node::getName(), YACS::ENGINE::Node::getState(), YACS::ENGINE::DynParaLoop::INIT_NODE, YACS::NOEVENT, updateStateForFinalizeNodeOnFinishedEventFrom(), updateStateForInitNodeOnFinishedEventFrom(), updateStateForWorkNodeOnFinishedEventFrom(), YACS::ENGINE::DynParaLoop::WORK_NODE, and YASSERT.
|
virtual |
Dump the node state to a stream.
| os | : the output stream |
Reimplemented from YACS::ENGINE::Node.
Definition at line 1102 of file ForEachLoop.cxx.
References YACS::ENGINE::DynParaLoop::_node, YACS::ENGINE::Node::getColorState(), YACS::ENGINE::Node::getEffectiveState(), YACS::ENGINE::Node::getId(), YACS::ENGINE::ComposedNode::getName(), yacsorb.CORBAEngineTest::state, and YACS::ENGINE::Node::writeDot().
|
friend |
Definition at line 156 of file ForEachLoop.hxx.
Referenced by exUpdateState().
|
friend |
Definition at line 155 of file ForEachLoop.hxx.
|
protected |
Definition at line 163 of file ForEachLoop.hxx.
Referenced by getProgress(), init(), updateStateForFinalizeNodeOnFinishedEventFrom(), updateStateForInitNodeOnFinishedEventFrom(), and updateStateForWorkNodeOnFinishedEventFrom().
|
protected |
ports created for TypeCodes correctness
Definition at line 169 of file ForEachLoop.hxx.
Referenced by exUpdateState(), init(), resetState(), and updateStateForWorkNodeOnFinishedEventFrom().
|
protected |
Definition at line 171 of file ForEachLoop.hxx.
Referenced by cleanDynGraph(), createOutputOutOfScopeInterceptors(), exUpdateState(), getPassedResults(), getProcessedData(), and storeOutValsInSeqForOutOfScopeUse().
|
protected |
Definition at line 170 of file ForEachLoop.hxx.
Referenced by cleanDynGraph(), exUpdateState(), getPassedResults(), getProcessedData(), prepareSequenceValues(), pushAllSequenceValues(), and storeOutValsInSeqForOutOfScopeUse().
|
protected |
ports linked to node outside the current scope
Definition at line 167 of file ForEachLoop.hxx.
Referenced by buildDelegateOf(), ForEachLoopGen(), releaseDelegateOf(), and ~ForEachLoopGen().
|
protected |
Definition at line 165 of file ForEachLoop.hxx.
Referenced by exUpdateState(), and getReadyTasks().
|
protected |
Definition at line 166 of file ForEachLoop.hxx.
Referenced by buildDelegateOf(), createOutputOutOfScopeInterceptors(), ForEachLoopGen(), getDelegateOf(), getOutPort(), getOutputPort(), getOutputPortType(), prepareSequenceValues(), pushAllSequenceValues(), releaseDelegateOf(), and ~ForEachLoopGen().
|
protected |
Definition at line 172 of file ForEachLoop.hxx.
Referenced by assignPassedResults(), exUpdateState(), getFinishedId(), init(), setProcessedData(), updateStateForWorkNodeOnFinishedEventFrom(), and ~ForEachLoopGen().
|
protected |
Definition at line 164 of file ForEachLoop.hxx.
Referenced by checkLinkPossibility(), exUpdateState(), getChildByShortName(), getFinishedId(), getInputPort(), getLocalInputPorts(), getNbOfElementsToBeProcessed(), getSetOfInputPort(), init(), and updateStateForWorkNodeOnFinishedEventFrom().
|
static |
Definition at line 232 of file ForEachLoop.hxx.
Referenced by InterceptorizeNameOfPort().
|
static |
Definition at line 159 of file ForEachLoop.hxx.
Referenced by getChildByShortName(), and YACS::ENGINE::VisitorSaveSchema::writeSimpleDataLinks().
|
staticprotected |
Definition at line 161 of file ForEachLoop.hxx.
Referenced by updateStateForWorkNodeOnFinishedEventFrom().