Rule Execution Server API

ilog.rules.factory
Class IlrTaskGotoNodeStatement

java.lang.Object
  extended by ilog.rules.factory.IlrBaseStatement
      extended by ilog.rules.factory.IlrFlowNodeStatement
          extended by ilog.rules.factory.IlrControlNodeStatement
              extended by ilog.rules.factory.IlrTaskGotoNodeStatement
All Implemented Interfaces:
ilog.rules.factory.IlrSourceElement, IlrStatement, Serializable

public class IlrTaskGotoNodeStatement
extends IlrControlNodeStatement

This class represents the class of a jump instruction in a ruleflow. It groups three kinds of jumps that can be found in a ruleflow:

Warning: Serialized objects of this class will not be compatible with future releases. The current serialization support is appropriate for short-term storage or RMI between applications running the same version of IBM Decision Server.

See Also:
IlrTaskFactory, IlrControlNodeStatement, IlrFlowNodeStatement, Serialized Form

Field Summary
static int Break
           This value is used to give a break behavior to the jump node, used in a while block.
static int Continue
           This value is used to give a continue behavior to the jump node, used in a while block.
static int Goto
           This value is used to give a goto behavior to the jump node.
 
Constructor Summary
IlrTaskGotoNodeStatement(int kind)
          Builds a jump instruction node for a ruleflow.
IlrTaskGotoNodeStatement(int kind, IlrFlowNodeStatement previousNode)
          Builds a jump instruction node for a ruleflow and connects the created node to the passed node.
 
Method Summary
 String getGotoLabel()
          Returns the label of the node on which the goto node points.
 int getKind()
          Returns the jump node kind.
 void setGotoLabel(String label)
          Sets the label of the node to which the ruleflow execution is directed after the execution of the goto node.
 
Methods inherited from class ilog.rules.factory.IlrFlowNodeStatement
exploreStatement, getName, setNextNode
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

Goto

public static final int Goto

This value is used to give a goto behavior to the jump node.

See Also:
Constant Field Values

Break

public static final int Break

This value is used to give a break behavior to the jump node, used in a while block.

See Also:
Constant Field Values

Continue

public static final int Continue

This value is used to give a continue behavior to the jump node, used in a while block.

See Also:
Constant Field Values
Constructor Detail

IlrTaskGotoNodeStatement

public IlrTaskGotoNodeStatement(int kind)
Builds a jump instruction node for a ruleflow.

We specify the kind of jump by passing one of the following values:

If a wrong value is passed, an IllegalArgumentException is thrown.

Parameters:
kind - The kind of jump node.

IlrTaskGotoNodeStatement

public IlrTaskGotoNodeStatement(int kind,
                                IlrFlowNodeStatement previousNode)
Builds a jump instruction node for a ruleflow and connects the created node to the passed node. This constructor must not be called to connect the new node to an IlrTaskIfNodeStatement nor to an IlrTaskSwitchNodeStatement; instead use IlrTaskIfNodeStatement.setTrueNode, IlrTaskIfNodeStatement.setFalseNode, IlrTaskSwitchNodeStatement.setCaseNode, or IlrTaskSwitchNodeStatement.setDefaultNode.

We specify the kind of jump by passing one of the following values:

If a wrong value is passed, an IllegalArgumentException is thrown.

Parameters:
kind - The kind of jump node.
previousNode - The node that is before the new node in the ruleflow. The two nodes are connected by calling the method IlrFlowNodeStatement.setNextNode.
Method Detail

setGotoLabel

public void setGotoLabel(String label)
Sets the label of the node to which the ruleflow execution is directed after the execution of the goto node. This method must be used only for a goto node whose kind is Goto, or else an IllegalArgumentException is thrown.

Parameters:
label - The label of the node on which the goto node points.

getGotoLabel

public String getGotoLabel()
Returns the label of the node on which the goto node points. This is the node that will be executed after the goto node.

Returns:
The label of the node pointed to by the this.

getKind

public int getKind()
Returns the jump node kind. The possible values are:

Returns:
The kind of the node.

Rule Execution Server API

© Copyright IBM Corp. 1987, 2013