Main Page   Packages   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members  

DoubleValue.java

00001 package gov.nasa.arc.ase.jpf.jvm.examine;
00002 
00003 import gov.nasa.arc.ase.jpf.*;
00004 import gov.nasa.arc.ase.jpf.jvm.*;
00005 
00006 public class DoubleValue implements iValue {
00007 
00008   private double value = 0;
00009 
00010   public DoubleValue(double v) {
00011     value = v;
00012   }  
00013   public DoubleValue(long v) {
00014     value = Types.longToDouble(v);
00015   }  
00016 /**
00017  * 
00018  * @return boolean
00019  * @param o java.lang.Object
00020  */
00021 public boolean equals(Object o) {
00022     if (o instanceof DoubleValue) return value == ((DoubleValue) o).value;
00023     return false;
00024 }
00025   public double getValue() {
00026     return value;
00027   }  
00028 /**
00029  * 
00030  * @return int
00031  */
00032 public int hashCode() {
00033     return new Double(value).hashCode();
00034 }
00035   public String toString() {
00036     return "" + value;
00037   }  
00038 }

Generated at Thu Feb 7 06:44:38 2002 for Bandera by doxygen1.2.10 written by Dimitri van Heesch, © 1997-2001