jopt.csp.spi.search.actions
Class GenerateLongAction

java.lang.Object
  extended byjopt.csp.spi.search.tree.AbstractSearchNodeAction
      extended byjopt.csp.spi.search.actions.GenerateLongAction
All Implemented Interfaces:
jopt.csp.search.SearchAction

public class GenerateLongAction
extends AbstractSearchNodeAction

Action that will generate values for an array of variables. It tries to bind each variable to a single value such that all constraints are satisfied and finishes searching upon finding the first consistent assignment.


Constructor Summary
GenerateLongAction(jopt.csp.variable.CspLongVariable[] vars)
          Creates new generation action
GenerateLongAction(jopt.csp.variable.CspLongVariable[] vars, jopt.csp.search.LongSelector selector)
          Creates new generation action
 
Method Summary
 jopt.csp.search.SearchAction performAction()
          Called by search tree to execute this action.
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

GenerateLongAction

public GenerateLongAction(jopt.csp.variable.CspLongVariable[] vars)
Creates new generation action

Parameters:
vars - Variable to instantiate

GenerateLongAction

public GenerateLongAction(jopt.csp.variable.CspLongVariable[] vars,
                          jopt.csp.search.LongSelector selector)
Creates new generation action

Parameters:
vars - Variable to instantiate
selector - Used to select next value to reduce domain of variable
Method Detail

performAction

public jopt.csp.search.SearchAction performAction()
                                           throws jopt.csp.variable.PropagationFailureException
Called by search tree to execute this action.

Returns:
Next action to execute in search
Throws:
jopt.csp.variable.PropagationFailureException

toString

public java.lang.String toString()