|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.globalmentor.beans.BoundPropertyObject
com.guiseframework.event.GuiseBoundPropertyObject
com.guiseframework.converter.AbstractConverter<V,L>
V - The value type this converter supports.L - The literal type of the lexical form of the value.public abstract class AbstractConverter<V,L>
An abstract implementation an object that can convert a value from and to its lexical form.
| Field Summary |
|---|
| Fields inherited from class com.globalmentor.beans.BoundPropertyObject |
|---|
NO_PROPERTY_CHANGE_LISTENERS, NO_VETOABLE_CHANGE_LISTENERS |
| Fields inherited from interface com.guiseframework.converter.Converter |
|---|
INVALID_VALUE_MESSAGE_PROPERTY |
| Constructor Summary | |
|---|---|
AbstractConverter()
|
|
| Method Summary | |
|---|---|
java.lang.String |
getInvalidValueMessage()
|
boolean |
isEquivalent(V value,
L literal)
Determines if the given literal in the lexical space is a valid representation of the given value in the value space. |
boolean |
isValidLiteral(L literal)
Determines whether a given literal value in the lexical space can be converted to a value in the value space. |
void |
setInvalidValueMessage(java.lang.String newInvalidValueMessage)
Sets the text of the invalid value message. |
| Methods inherited from class com.guiseframework.event.GuiseBoundPropertyObject |
|---|
getSession |
| Methods inherited from class com.globalmentor.beans.BoundPropertyObject |
|---|
addPropertyChangeListener, addPropertyChangeListener, addVetoableChangeListener, addVetoableChangeListener, createPostponedPropertyChangeEvent, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, fireVetoableChange, fireVetoableChange, fireVetoableChange, getForwardPropertyChangeListener, getPropertyChangeListeners, getPropertyChangeListeners, getPropertyChangeSupport, getRepeatPropertyChangeListener, getRepeatVetoableChangeListener, getVetoableChangeListeners, getVetoableChangeListeners, getVetoableChangeSupport, hasPropertyChangeListeners, hasVetoableChangeListeners, removePropertyChangeListener, removePropertyChangeListener, removeVetoableChangeListener, removeVetoableChangeListener |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface com.guiseframework.converter.Converter |
|---|
convertLiteral, convertValue, getSession |
| Methods inherited from interface com.globalmentor.beans.PropertyBindable |
|---|
addPropertyChangeListener, addPropertyChangeListener, getPropertyChangeListeners, getPropertyChangeListeners, hasPropertyChangeListeners, removePropertyChangeListener, removePropertyChangeListener |
| Constructor Detail |
|---|
public AbstractConverter()
| Method Detail |
|---|
public java.lang.String getInvalidValueMessage()
getInvalidValueMessage in interface Converter<V,L>public void setInvalidValueMessage(java.lang.String newInvalidValueMessage)
setInvalidValueMessage in interface Converter<V,L>newInvalidValueMessage - The new text of the invalid value message, which may include a resource reference.
java.lang.NullPointerException - if the given message is null.Converter.INVALID_VALUE_MESSAGE_PROPERTYpublic boolean isValidLiteral(L literal)
false if conversion is unsuccessful.
isValidLiteral in interface Converter<V,L>literal - The literal value to validate.
true if the literal is valid, else false.
public boolean isEquivalent(V value,
L literal)
null values can correctly be compared using Object.equals(Object).
isEquivalent in interface Converter<V,L>value - The value to compare.literal - The literal value in the lexical space to compare with the value after conversion.
true if the given literal in the lexical space is a valid representation of the given value in the value space.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||