choco.mem
Class StoredFloat

java.lang.Object
  extended by choco.mem.StoredFloat

public class StoredFloat
extends java.lang.Object

A class implementing a backtrackable float variable.


Constructor Summary
StoredFloat(Environment env)
          Constructs a stored search with an unknown initial value.
StoredFloat(Environment env, double d)
          Constructs a stored search with an initial value.
 
Method Summary
 void add(double delta)
          modifying a StoredInt by an increment
 double get()
          Returns the current value.
 Environment getEnvironment()
          Retrieving the environment
 boolean isKnown()
          Checks if a value is currently stored.
 void set(double y)
          Modifies the value and stores if needed the former value on the trailing stack.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

StoredFloat

public StoredFloat(Environment env)
Constructs a stored search with an unknown initial value. Note: this constructor should not be used directly: one should instead use the Environment factory


StoredFloat

public StoredFloat(Environment env,
                   double d)
Constructs a stored search with an initial value. Note: this constructor should not be used directly: one should instead use the Environment factory

Method Detail

get

public double get()
Returns the current value.


isKnown

public boolean isKnown()
Checks if a value is currently stored.


set

public void set(double y)
Modifies the value and stores if needed the former value on the trailing stack.


add

public void add(double delta)
modifying a StoredInt by an increment

Parameters:
delta -

getEnvironment

public Environment getEnvironment()
Retrieving the environment