|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.dbunit.dataset.datatype.DataType
org.dbunit.dataset.datatype.AbstractDataType
org.dbunit.dataset.datatype.NumberDataType
org.dbunit.dataset.datatype.NumberTolerantDataType
public final class NumberTolerantDataType
Copy from org/dbunit/dataset/datatype/NumberDataType.java with
extended version of the compare method in order to respect precision tolerance.
This is comparable to the junit method assert(double val1, double val2, double toleratedDelta).
| Field Summary |
|---|
| Fields inherited from class org.dbunit.dataset.datatype.DataType |
|---|
BIGINT, BINARY, BIT, BLOB, BOOLEAN, CHAR, CLOB, DATE, DECIMAL, DOUBLE, FLOAT, INTEGER, LONGVARBINARY, LONGVARCHAR, NUMERIC, REAL, SMALLINT, TIME, TIMESTAMP, TINYINT, UNKNOWN, VARBINARY, VARCHAR |
| Method Summary | |
|---|---|
int |
compare(java.lang.Object o1,
java.lang.Object o2)
The only method overwritten from the base implementation to compare numbers allowing a tolerance |
double |
getDelta()
|
| Methods inherited from class org.dbunit.dataset.datatype.NumberDataType |
|---|
getSqlValue, setSqlValue, typeCast |
| Methods inherited from class org.dbunit.dataset.datatype.AbstractDataType |
|---|
getSqlType, getTypeClass, isDateTime, isNumber, loadClass, toString |
| Methods inherited from class org.dbunit.dataset.datatype.DataType |
|---|
asString, forObject, forSqlType, forSqlTypeName |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Method Detail |
|---|
public double getDelta()
public int compare(java.lang.Object o1,
java.lang.Object o2)
throws TypeCastException
compare in class AbstractDataTypeTypeCastException - if the arguments' types prevent them from
being compared by this Comparator.AbstractDataType.compare(java.lang.Object, java.lang.Object)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||