Iterative Process
Inheritors
Types
Properties
Returns system time in nanoseconds that the iterative process started
Returns system time in nanoseconds that the iterative process ended
Indicates the status of the iterative process
A flag to indicate whether the iterative process is done A iterative process can be done if: 1) it ran all of its steps 2) it was ended by a client prior to completing all of its steps 3) it ended because it exceeded its maximum allowable execution time before completing all of its steps. 4) its end condition was satisfied
Checks if the iterative process is in the initialized state After the iterative process has been initialized this method will return true
Indicates that the iterative process is currently running an individual step
Checks if the iterative process is in the completed step state After the iterative process has successfully completed a step this property will be true
The maximum allotted (suggested) execution (real) clock for the entire iterative process in nanoseconds. This is a suggested time because the execution time requirement is only checked after the completion of an individual step After it is discovered that cumulative time for executing the step has exceeded the maximum time, then the iterative process will be ended (perhaps) not completing other steps.
A reference to the created state for the iterative process A iterative process is in the created state when it is first constructed and can then only transition to the initialized state
A reference to an object related to the current step of the process It can be passed to observers
A reference to the ended state of the iterative process A iterative process is in the ended state after the process is told to end
A reference to the initialized state of the iterative process A iterative process is in the initialized state after the method initialize() is called from a proper state.
A reference to the step-completed state of the iterative process A iterative process is in the step-completed state after the runNext method is called from a proper state
Returns the number of steps completed since the iterative process was last initialized
A reference to the current state of the iterative process
A string message for why stop() was called.
Functions
The iterative process will continue until there are no more steps or its maximum execution time has been reached, whichever comes first. If this method is called the iterative process will stop processing (terminate) before the next step and not process the next step in the process. The current step will be completed. This method can be used to stop the process at an arbitrary step. Once stopped, the process must be restarted.
This method should check to see if another step is necessary for the iterative process. True means that the process has another step to be executed. False, means that no more steps are available for execution.
Initializes the iterative process prior to running any steps This must be done prior to calling runNext();
This method tells the iterative process to execute the current step. Typical usage is to call this after calling next() to advance to the next step. This method should throw a NoSuchStepException if there are no more steps to run, and it is told to run the step.
This sets a flag to indicate to the process that it should stop after the next step is completed. This is different from end(). Calling end() immediately places the process in the End state. The process needs to be in a valid state before end() can be used. Calling stop tells the process to eventually get into the end state. stop() can be used to arbitrarily stop the process based on some user defined condition.