|
Joda System API | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.joda.property.impl.AbstractModelElement | +--org.joda.property.impl.AbstractProperty | +--org.joda.property.impl.type.AbstractNumericProperty
Abstract class useful for Numeric property implementations.
Nested Class Summary |
Nested classes inherited from class org.joda.property.Property |
Property.Internal |
Field Summary |
Fields inherited from interface org.joda.property.type.NumericProperty |
DEFAULT_TYPE |
Constructor Summary | |
AbstractNumericProperty()
Constructor |
Method Summary | |
int |
compareTo(double anotherValue)
Compare the property's value to the passed in value. |
int |
compareTo(long anotherValue)
Compare the property's value to the passed in value. |
double |
doubleValue()
Get the property's value as a double. |
boolean |
equals(double anotherValue)
Is the property's value equal to the passed in value. |
boolean |
equals(long anotherValue)
Is the property's value equal to the passed in value. |
float |
floatValue()
Get the property's value as a float. |
protected java.lang.Number |
getInternal()
Get the value from the data store |
int |
intValue()
Get the property's value as an int. |
boolean |
isGreaterThan(double anotherValue)
Is the property's value greater than the passed in value. |
boolean |
isGreaterThan(long anotherValue)
Is the property's value greater than the passed in value. |
boolean |
isGreaterThan(java.lang.Object anotherValue)
Is the property's value greater than the passed in value. |
boolean |
isLessThan(double anotherValue)
Is the property's value less than the passed in value. |
boolean |
isLessThan(long anotherValue)
Is the property's value less than the passed in value. |
boolean |
isLessThan(java.lang.Object anotherValue)
Is the property's value less than the passed in value. |
long |
longValue()
Get the property's value as a long. |
protected void |
setInternal(java.lang.Number newValue)
Set the value to the data store |
java.lang.Double |
toDouble()
Get the property's value as a Double. |
java.lang.Float |
toFloat()
Get the property's value as a Float. |
java.lang.Integer |
toInteger()
Get the property's value as an Integer. |
java.lang.Long |
toLong()
Get the property's value as a Long. |
java.lang.Number |
toNumber()
Get the property's value as a Number. |
java.lang.Object |
toObject()
Get the property's value as an object. |
Methods inherited from class org.joda.property.impl.AbstractProperty |
addPropertyChangeListener, bean, checkArgumentNotNull, checkModifiable, checkValueNotNull, checkValueNotNull, cloneDeep, convertObject, createClonedProperty, data, equals, equalsValue, firePropertyChange, firePropertyChange, getContentName, getContentType, getPropertyName, getThis, hashCode, initBeanCreated, initPropertyCreated, isModifiable, isNull, isReadOnly, populateClonedProperty, removePropertyChangeListener, set, setModifiable, setReadOnly, toDataString, toString |
Methods inherited from class org.joda.property.impl.AbstractModelElement |
getAttribute, getAttributeCount, getAttributeMap, setAttribute |
Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Methods inherited from interface org.joda.property.type.NumericProperty |
add, add, add, divideBy, divideBy, divideBy, multiplyBy, multiplyBy, multiplyBy, negate, set, set, subtract, subtract, subtract, toBigDecimal |
Methods inherited from interface org.joda.property.type.DataProperty |
toDataString |
Methods inherited from interface org.joda.property.Property |
addPropertyChangeListener, bean, equals, equalsValue, firePropertyChange, getContentName, getContentType, getPropertyName, getPropertyType, hashCode, isModifiable, isNull, isReadOnly, removePropertyChangeListener, set, setModifiable, setReadOnly, toString |
Methods inherited from interface org.joda.property.ModelElement |
getAttribute, getAttributeCount, getAttributeMap, setAttribute |
Methods inherited from interface java.lang.Comparable |
compareTo |
Constructor Detail |
public AbstractNumericProperty()
Method Detail |
protected java.lang.Number getInternal()
protected void setInternal(java.lang.Number newValue)
public java.lang.Object toObject()
Property
This method has strong semantics such that where a and b are
properties of the same type, it must be true that:
b.set( a.toObject() );
a.equals(b);
In other words, the object contains all the data necessary to
recreate the property's value.
toObject
in interface Property
toObject
in class AbstractProperty
Property#toObject()
public java.lang.Number toNumber()
NumericProperty
toNumber
in interface NumericProperty
NumericProperty.toNumber()
public boolean equals(long anotherValue)
NumericProperty
equals
in interface NumericProperty
anotherValue
- a value to compare the property to
NumericProperty.equals(long)
public boolean equals(double anotherValue)
NumericProperty
equals
in interface NumericProperty
anotherValue
- a value to compare the property to
NumericProperty.equals(double)
public int compareTo(long anotherValue)
NumericProperty
compareTo
in interface NumericProperty
anotherValue
- a value to compare the property to
NumericProperty.compareTo(long)
public int compareTo(double anotherValue)
NumericProperty
compareTo
in interface NumericProperty
anotherValue
- a value to compare the property to
NumericProperty.compareTo(double)
public boolean isLessThan(long anotherValue)
NumericProperty
isLessThan
in interface NumericProperty
anotherValue
- a value to compare the property to
NumericProperty.isLessThan(long)
public boolean isLessThan(double anotherValue)
NumericProperty
isLessThan
in interface NumericProperty
anotherValue
- a value to compare the property to
NumericProperty.isLessThan(double)
public boolean isLessThan(java.lang.Object anotherValue)
NumericProperty
isLessThan
in interface NumericProperty
anotherValue
- a value to compare the property to
NumericProperty.isLessThan(Object)
public boolean isGreaterThan(long anotherValue)
NumericProperty
isGreaterThan
in interface NumericProperty
anotherValue
- a value to compare the property to
NumericProperty.isGreaterThan(long)
public boolean isGreaterThan(double anotherValue)
NumericProperty
isGreaterThan
in interface NumericProperty
anotherValue
- a value to compare the property to
NumericProperty.isGreaterThan(double)
public boolean isGreaterThan(java.lang.Object anotherValue)
NumericProperty
isGreaterThan
in interface NumericProperty
anotherValue
- a value to compare the property to
NumericProperty.isGreaterThan(Object)
public int intValue()
NumericProperty
intValue
in interface NumericProperty
NumericProperty.intValue()
public long longValue()
NumericProperty
longValue
in interface NumericProperty
NumericProperty.longValue()
public float floatValue()
NumericProperty
floatValue
in interface NumericProperty
NumericProperty.floatValue()
public double doubleValue()
NumericProperty
doubleValue
in interface NumericProperty
NumericProperty.doubleValue()
public java.lang.Integer toInteger()
NumericProperty
toInteger
in interface NumericProperty
NumericProperty.toInteger()
public java.lang.Long toLong()
NumericProperty
toLong
in interface NumericProperty
NumericProperty.toLong()
public java.lang.Float toFloat()
NumericProperty
toFloat
in interface NumericProperty
NumericProperty.toFloat()
public java.lang.Double toDouble()
NumericProperty
toDouble
in interface NumericProperty
NumericProperty.toDouble()
|
Joda System API | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |