omnics
Class IntVar

java.lang.Object
  extended by omnics.Var
      extended by omnics.IntVar
All Implemented Interfaces:
java.io.Serializable, java.lang.Comparable

public class IntVar
extends Var

Convenience class for working with integer variables.

Author:
Cristian Frasinaru
See Also:
Serialized Form

Constructor Summary
IntVar(java.lang.String name, Domain domain)
          Creates a new instance of IntVar
IntVar(java.lang.String name, int from, int to)
          Creates a new instance of IntVar
 
Method Summary
 java.lang.Integer getValue()
          Gets the value assigned to this variable in the current partial solution.
 
Methods inherited from class omnics.Var
compareTo, getConstraints, getConstraints, getData, getDomain, getIndex, getInitialDomain, getName, getProblem, getSupportFor, isActive, isInstantiated, isTarget, restoreInitialDomain, setActive, setData, setDomain, setName, setTarget, setValue, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

IntVar

public IntVar(java.lang.String name,
              int from,
              int to)
Creates a new instance of IntVar


IntVar

public IntVar(java.lang.String name,
              Domain domain)
Creates a new instance of IntVar

Method Detail

getValue

public java.lang.Integer getValue()
Description copied from class: Var
Gets the value assigned to this variable in the current partial solution.

Overrides:
getValue in class Var
Returns:
the value assigned to this variable in the current partial solution or null if the variable has not been instantiated