jopt.csp.variable
Interface CspIntSetVariable

All Superinterfaces:
CspSetVariable, CspVariable

public interface CspIntSetVariable
extends CspSetVariable

Interface implemented by variables representing a set of integer values


Method Summary
 void addRequired(int value)
          Adds a required value to the set
 boolean isInDomain(int val)
          Returns true if the specified value is in this variable's domain
 boolean isPossible(int value)
          Returns true if the specified value is possible
 boolean isRequired(int value)
          Returns true if the specified value is required
 void removePossible(int value)
          Removes a value from the possible set
 
Methods inherited from interface jopt.csp.variable.CspSetVariable
addRequired, addRequired, getName, getPossibleCardinality, getPossibleSet, getRequiredCardinality, getRequiredSet, getSize, isInDomain, isPossible, isRequired, removePossible, removePossible, setName
 
Methods inherited from interface jopt.csp.variable.CspVariable
isBound
 

Method Detail

isInDomain

public boolean isInDomain(int val)
Returns true if the specified value is in this variable's domain

Parameters:
val - value to check if it is in the domain
Returns:
true if value is in domain

isRequired

public boolean isRequired(int value)
Returns true if the specified value is required

Parameters:
value - value to check if it is required
Returns:
true if value is required

isPossible

public boolean isPossible(int value)
Returns true if the specified value is possible

Parameters:
value - value to verify if it is possible
Returns:
true if value is possible

addRequired

public void addRequired(int value)
                 throws PropagationFailureException
Adds a required value to the set

Parameters:
value - value to add to the required set
Throws:
PropagationFailureException

removePossible

public void removePossible(int value)
                    throws PropagationFailureException
Removes a value from the possible set

Parameters:
value - value to remove from the required set
Throws:
PropagationFailureException