org.inria.ns.reflex.processor.asl
Class InterimStepAction

java.lang.Object
  extended by org.inria.ns.reflex.processor.core.AbstractAction
      extended by org.inria.ns.reflex.processor.asl.AbstractStepAction
          extended by org.inria.ns.reflex.processor.asl.InterimStepAction
All Implemented Interfaces:
Executable, Identifiable, Presentable, NamespaceContextFactory

public class InterimStepAction
extends AbstractStepAction

An interim step has two facets : this STEP action, and a context-feeder (the InterimStepAction.InterimAction inner class).

At runtime, the InterimAction feeds the context with the InterimStepAction outer class.

The InterimStepAction class is the facet of the interim step that is invoked when a matcher matches.

InterimStepAction will be used at the invokation phase to perform the interim step.

Author:
Philippe Poulard

Nested Class Summary
 class InterimStepAction.InterimAction
          An interim step has two facets : this context-feeder, and a STEP action (the InterimStepAction outer class).
 
Nested classes/interfaces inherited from class org.inria.ns.reflex.processor.asl.AbstractStepAction
AbstractStepAction.ItemsLists
 
Nested classes/interfaces inherited from class org.inria.ns.reflex.processor.core.AbstractAction
AbstractAction.ParameterAdapter, AbstractAction.UselessAction
 
Field Summary
 
Fields inherited from class org.inria.ns.reflex.processor.asl.AbstractStepAction
STEP_USED_BUBBLE_MESSAGE
 
Fields inherited from class org.inria.ns.reflex.processor.core.AbstractAction
actions, parent, processorInstance
 
Constructor Summary
InterimStepAction(boolean replace, Element element, AbstractAction parent)
          Creates a new instance of InterimAction with unstable repeating mode.
 
Method Summary
 int getMinOccurs(DataSet dataSet)
          An interim step is optional.
 boolean isSubstituteStep()
          Indicates if the interim step definitively replaces the disrupted step or not.
static AbstractAction unmarshal(AbstractAction parent, Element element)
          XML unmarshaller for <asl:interim>.
 
Methods inherited from class org.inria.ns.reflex.processor.asl.AbstractStepAction
computeOccurs, getId, getMaxOccurs, invokeHandler, runAction, stableRun, unstableRun
 
Methods inherited from class org.inria.ns.reflex.processor.core.AbstractAction
addAction, addFallbackAction, createContext, getCanonicalPath, getFallbackAction, getLocalFallbackAction, getLogger, getNamespaceContext, getNode, getParent, recover, recover, removeFallbackAction, reorganize, run, runActions, toPrettyString, toPrettyString, toString
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

InterimStepAction

public InterimStepAction(boolean replace,
                         Element element,
                         AbstractAction parent)
                  throws XPathException
Creates a new instance of InterimAction with unstable repeating mode.

Parameters:
replace - Indicates wether this step replaces the upper step or not.
node - The node from which the action has been unmarshalled. Used for namespace prefix resolution when performing XPath expressions.
parent - The action depending from.
Throws:
XPathException
Method Detail

unmarshal

public static AbstractAction unmarshal(AbstractAction parent,
                                       Element element)
                                throws XMLException
XML unmarshaller for <asl:interim>.

Parameters:
parent - The action depending from.
element - The XML element to unmarshall.
Returns:
An InterimAction related to an InterimStepAction.
Throws:
UnmarshalException - When the element and its content is not those expected.
XMLException

isSubstituteStep

public boolean isSubstituteStep()
Indicates if the interim step definitively replaces the disrupted step or not.

Returns:
true if this step replaces the upper disrupted step, false otherwise.

getMinOccurs

public int getMinOccurs(DataSet dataSet)
                 throws ExecutionException,
                        XPathException
An interim step is optional.

Overrides:
getMinOccurs in class AbstractStepAction
Parameters:
dataSet - The set of datas used when the action is running.
Returns:
0
Throws:
ExecutionException
XPathException
See Also:
AbstractStepAction.getMinOccurs(org.inria.ns.reflex.processor.DataSet)