|
JML | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectorg.jmlspecs.models.JMLDouble
A reflection of Double that implements JMLType.
Double,
JMLDouble| Field Summary | |
private double |
doubleValue
The double that is the abstract value of this object. |
| Constructor Summary | |
JMLDouble()
Initialize this object to contain zero. |
|
JMLDouble(double inDouble)
Initialize this object to contain the given double. |
|
JMLDouble(int inInt)
Initialize this object to contain an approximation to the given integer. |
|
JMLDouble(Double inDouble)
Initialize this object to contain the value of the given Double. |
|
JMLDouble(String s)
Initialize this object to contain the value given by the string argument. |
|
| Method Summary | |
boolean |
approximatelyEqualTo(double d2,
double epsilon)
Tell whether relative difference of this JMLDouble and the arg is within the given epsilon. |
static boolean |
approximatelyEqualTo(double d1,
double d2,
double epsilon)
Tell whether relative difference of the two arguments is within the given epsilon. |
boolean |
approximatelyEqualTo(Double d2,
double epsilon)
Tell whether relative difference of this JMLDouble and the arg is within the given epsilon. |
boolean |
approximatelyEqualTo(JMLDouble d2,
double epsilon)
Tell whether relative difference of this JMLDouble and the arg is within the given epsilon. |
static boolean |
approximatelyEqualTo(JMLDouble d1,
double d2,
double epsilon)
Tell whether relative difference of this JMLDouble and the arg is within the given epsilon. |
static boolean |
approximatelyEqualTo(JMLDouble d1,
Double d2,
double epsilon)
Tell whether relative difference of this JMLDouble and the arg is within the given epsilon. |
static boolean |
approximatelyEqualTo(JMLDouble d1,
JMLDouble d2,
double epsilon)
Tell whether relative difference of this JMLDouble and the arg is within the given epsilon. |
Object |
clone()
Return a clone of this object. |
int |
compareTo(Object op2)
Compare this to op2, returning a comparison code. |
JMLDouble |
dividedBy(JMLDouble d2)
Return the quotient of this divided by the given argument. |
double |
doubleValue()
Return the double contained in this object. |
boolean |
equals(Object op2)
Tell whether this object is equal to the argument. |
Double |
getDouble()
Return a Double containing the double contained in this object. |
boolean |
greaterThan(JMLDouble d2)
Tell whether this is strictly greater than the given argument. |
boolean |
greaterThanOrEqualTo(JMLDouble d2)
Tell whether this is greater than or equal to the given argument. |
int |
hashCode()
Return a hash code for this object. |
boolean |
isInfinite()
Tell if this object contains either positive or negative infinity. |
boolean |
isNaN()
Tell if this object contains NaN (not a number). |
boolean |
isZero()
Tell if this object contains zero (either positive or negative). |
static boolean |
isZero(double d)
Tell if the argument is zero (either positive or negative). |
boolean |
lessThan(JMLDouble d2)
Tell whether this is strictly less than the given argument. |
boolean |
lessThanOrEqualTo(JMLDouble d2)
Tell whether this is less than or equal to the given argument. |
JMLDouble |
minus(JMLDouble d2)
Return the difference between this and the given argument. |
JMLDouble |
negated()
Return the negation of this. |
JMLDouble |
plus(JMLDouble d2)
Return the sum of this and the given argument. |
JMLDouble |
remainderBy(JMLDouble d2)
Return the remainder of this divided by the given argument. |
JMLDouble |
times(JMLDouble d2)
Return the product of this and the given argument. |
String |
toString()
Return a string representation of this object. |
boolean |
withinEpsilonOf(double d2,
double epsilon)
Tell whether absolute value of difference of this JMLDouble and the arg is within the given epsilon. |
static boolean |
withinEpsilonOf(double d1,
double d2,
double epsilon)
Tell whether absolute value of difference of the two arguments is within the given epsilon. |
boolean |
withinEpsilonOf(Double d2,
double epsilon)
Tell whether absolute value of difference of this JMLDouble and the arg is within the given epsilon. |
boolean |
withinEpsilonOf(JMLDouble d2,
double epsilon)
Tell whether absolute value of difference of this JMLDouble and the arg is within the given epsilon. |
static boolean |
withinEpsilonOf(JMLDouble d1,
double d2,
double epsilon)
Tell whether absolute value of difference of this JMLDouble and the arg is within the given epsilon. |
static boolean |
withinEpsilonOf(JMLDouble d1,
Double d2,
double epsilon)
Tell whether absolute value of difference of this JMLDouble and the arg is within the given epsilon. |
static boolean |
withinEpsilonOf(JMLDouble d1,
JMLDouble d2,
double epsilon)
Tell whether absolute value of difference of this JMLDouble and the arg is within the given epsilon. |
| Methods inherited from class java.lang.Object |
finalize, getClass, notify, notifyAll, wait, wait, wait |
| Field Detail |
private double doubleValue
| Constructor Detail |
public JMLDouble()
public JMLDouble(double inDouble)
public JMLDouble(int inInt)
public JMLDouble(Double inDouble)
public JMLDouble(String s)
throws NumberFormatException
NumberFormatException| Method Detail |
public boolean isInfinite()
public boolean isNaN()
public Object clone()
clone in interface JMLTypeclone in class Object
public int compareTo(Object op2)
throws ClassCastException
compareTo in interface JMLComparableop2 - the object this is compared to.
ClassCastException - when o is not a JMLDouble.public static boolean isZero(double d)
public boolean isZero()
public boolean equals(Object op2)
equals in interface JMLTypeequals in class Objectpublic int hashCode()
hashCode in interface JMLTypehashCode in class Objectpublic double doubleValue()
public Double getDouble()
public JMLDouble negated()
public JMLDouble plus(JMLDouble d2)
public JMLDouble minus(JMLDouble d2)
public JMLDouble times(JMLDouble d2)
public JMLDouble dividedBy(JMLDouble d2)
public JMLDouble remainderBy(JMLDouble d2)
public boolean greaterThan(JMLDouble d2)
public boolean lessThan(JMLDouble d2)
public boolean greaterThanOrEqualTo(JMLDouble d2)
public boolean lessThanOrEqualTo(JMLDouble d2)
public String toString()
toString in class Object
public boolean withinEpsilonOf(JMLDouble d2,
double epsilon)
public boolean approximatelyEqualTo(JMLDouble d2,
double epsilon)
approximatelyEqualTo(double, double, double)
public boolean withinEpsilonOf(Double d2,
double epsilon)
public boolean approximatelyEqualTo(Double d2,
double epsilon)
approximatelyEqualTo(double, double, double)
public boolean withinEpsilonOf(double d2,
double epsilon)
public boolean approximatelyEqualTo(double d2,
double epsilon)
approximatelyEqualTo(double, double, double)
public static boolean withinEpsilonOf(double d1,
double d2,
double epsilon)
public static boolean approximatelyEqualTo(double d1,
double d2,
double epsilon)
public static boolean withinEpsilonOf(JMLDouble d1,
JMLDouble d2,
double epsilon)
public static boolean approximatelyEqualTo(JMLDouble d1,
JMLDouble d2,
double epsilon)
approximatelyEqualTo(double, double, double)
public static boolean withinEpsilonOf(JMLDouble d1,
Double d2,
double epsilon)
public static boolean approximatelyEqualTo(JMLDouble d1,
Double d2,
double epsilon)
approximatelyEqualTo(double, double, double)
public static boolean withinEpsilonOf(JMLDouble d1,
double d2,
double epsilon)
public static boolean approximatelyEqualTo(JMLDouble d1,
double d2,
double epsilon)
approximatelyEqualTo(double, double, double)
|
JML | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||