Package net.simplace.pipe.control
Class FWLoopProcessor
java.lang.Object
net.simplace.pipe.control.FWProcessor
net.simplace.pipe.control.FWLoopProcessor
- Direct Known Subclasses:
CreateSessionProcessor,LoopCounterProcessor,LoopListProcessor,LoopParameterProcessor,LoopScenarioProcessor,LoopSimModelRunProcessor,LoopSystemscenarioProcessor,LoopXMLChildProcessor
Looping processors are running a given Pipeline ${PipeID} several times. The number of loops
is given by the central value (see parameterlist). Loops are separated by default
(${separateLoops} (TRUE|FALSE)). For non separated loops all parameter values created in the
pipeline process are written to parameter map.
Within the looped pipeline you can find the total run count ${runCount} and the run count ${Count}
This looping processor takes the parameter in ${looplist} converted to list or map to loop the
pipeline. Additionally to Count and runCount you can find the actual looplistentry in
parametername: "${looplist}.loop",
for maps the actual looplistvalue in parametername: "${looplist}.loopvalue"
as a special the looplist can be a String too.
Format: comma-separated for lists:
"first,next,last"
or
Format: comma-separated with = and leading and ending brace for maps:
"{first=firstvalue,next=nextvalue,last=lastvalue}
further parameter: ${startIndex} gives the first index of ${Count}-Parameter in looping pipeline.
- Author:
- Andreas Enders
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected intIndicates the count of loops created by this processor - for non loop processors: -1protected Mapprotected StringIndicates the ID of the Pipe to be loopedprotected booleanSeparate different runs from each others dataFields inherited from class net.simplace.pipe.control.FWProcessor
iAllreadyLoopedCount, iContainer, iInObservable, iObservable, iProgressTasks -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected booleanCan be overridden to perform semantic checks on the pipeline Input.protected booleanCan be overridden to perform semantic checks on the pipeline Input.clone()Creates a connectlet by dynamically instancing the class given in the JDM element.intvoidprotected booleaninterveneRunLoop(FWObservable observable) overwrite this method to work on parameters before loop runningprotected final FWObservablerunLoop(String aLoopListParam, Map<?, Object> aLoopObjectMap, FWObservable aObservable) Must be overwritten to implement concrete pipe procedure.Methods inherited from class net.simplace.pipe.control.FWProcessor
containsParameter, createProcessor, createProcessor, fireTaskEvent, getAllStringInParameters, getConfiguration, getInitialParameters, getInParameter, getInParameter, getInParameters, getNewProgressTask, getOutParameter, getOutParameterKeys, getPipeLine, getProgressTask, getStringInParameter, getStringInParameter, getSystemID, hasConfiguration, isEndOfPipe, pipe, process, removeOutParameter, setConfiguration, setEndOfPipeFlag, setInitialParameters, setInParameterMap, setLoopedCount, setOutParameter, setStateOfTask, setStateProgressing, toXML
-
Field Details
-
iLoopCount
protected int iLoopCountIndicates the count of loops created by this processor - for non loop processors: -1 -
iLoopPipeId
Indicates the ID of the Pipe to be looped -
iSeparateRuns
protected boolean iSeparateRunsSeparate different runs from each others data -
iLoopMap
-
-
Constructor Details
-
FWLoopProcessor
public FWLoopProcessor()
-
-
Method Details
-
clone
Description copied from class:FWProcessorCreates a connectlet by dynamically instancing the class given in the JDM element.- Overrides:
clonein classFWProcessor
-
runLoop
protected final FWObservable runLoop(String aLoopListParam, Map<?, Object> aLoopObjectMap, FWObservable aObservable) throws PipeLineExceptionMust be overwritten to implement concrete pipe procedure.- Parameters:
aLoopListParam-aLoopObjectMap-aObservable-- Returns:
- FWObservable
- Throws:
PipeLineException
-
interveneRunLoop
overwrite this method to work on parameters before loop running- Parameters:
observable-- Returns:
- success
-
checkInParameterMap
protected boolean checkInParameterMap()Description copied from class:FWProcessorCan be overridden to perform semantic checks on the pipeline Input.- Overrides:
checkInParameterMapin classFWProcessor- Returns:
- true if not overridden by implementations
-
checkOutParameterMap
protected boolean checkOutParameterMap()Description copied from class:FWProcessorCan be overridden to perform semantic checks on the pipeline Input.- Overrides:
checkOutParameterMapin classFWProcessor- Returns:
- true if not overridden
-
getLoopCount
public int getLoopCount()- Returns:
- the the count of loops, invoked by this processor
-
getLoopPipeID
- Returns:
- the the count of loops, invoked by this processor
-
initLoop
- Parameters:
aParameterMap-
-
getLoopMap
- Returns:
- the LoopMap
-