Class BoundsVarValue

java.lang.Object
org.jacop.floats.constraints.linear.BoundsVarValue
All Implemented Interfaces:
Cloneable, MutableVarValue

class BoundsVarValue extends Object implements MutableVarValue, Cloneable
Defines a current bounds for the Linear constraint.
Version:
4.9
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    (package private) double
     
    (package private) double
     
    (package private) double
     
    (package private) BoundsVarValue
     
    (package private) int
     
    (package private) double
     
  • Constructor Summary

    Constructors
    Constructor
    Description
     
    BoundsVarValue(double min, double max, double lb, double ub)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    It clones the value of mutable variable.
    It returns the earlier value of mutable variable.
    void
    It replaces the earlier value of a mutable variable with value passed as parameter.
    void
    setStamp(int s)
    It sets the stamp of value of mutable variable.
    (package private) void
    setValue(double min, double max, double lb, double ub)
     
    int
    It returns the stamp value of value of mutable variable.
    It returns string representation of the current value of mutable variable.

    Methods inherited from class java.lang.Object

    equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
  • Field Details

    • previousBoundsVarValue

      BoundsVarValue previousBoundsVarValue
    • min

      double min
    • max

      double max
    • lb

      double lb
    • ub

      double ub
    • stamp

      int stamp
  • Constructor Details

    • BoundsVarValue

      BoundsVarValue()
    • BoundsVarValue

      BoundsVarValue(double min, double max, double lb, double ub)
  • Method Details

    • clone

      public Object clone()
      Description copied from interface: MutableVarValue
      It clones the value of mutable variable. It includes the stamp, pointer to earlier value, and current value of variable.
      Specified by:
      clone in interface MutableVarValue
      Overrides:
      clone in class Object
      Returns:
      clone of the mutable variable value.
    • previous

      public MutableVarValue previous()
      Description copied from interface: MutableVarValue
      It returns the earlier value of mutable variable.
      Specified by:
      previous in interface MutableVarValue
      Returns:
      earlier value of mutable variable.
    • setPrevious

      public void setPrevious(MutableVarValue n)
      Description copied from interface: MutableVarValue
      It replaces the earlier value of a mutable variable with value passed as parameter.
      Specified by:
      setPrevious in interface MutableVarValue
      Parameters:
      n - the previous value for this mutable variable.
    • setStamp

      public void setStamp(int s)
      Description copied from interface: MutableVarValue
      It sets the stamp of value of mutable variable.
      Specified by:
      setStamp in interface MutableVarValue
      Parameters:
      s - the new stamp of value of mutable variable
    • setValue

      void setValue(double min, double max, double lb, double ub)
    • stamp

      public int stamp()
      Description copied from interface: MutableVarValue
      It returns the stamp value of value of mutable variable.
      Specified by:
      stamp in interface MutableVarValue
      Returns:
      the current stamp of value of mutable variable.
    • toString

      public String toString()
      Description copied from interface: MutableVarValue
      It returns string representation of the current value of mutable variable.
      Specified by:
      toString in interface MutableVarValue
      Overrides:
      toString in class Object