org.promotego.editors
Class BeanIdEditor<T extends BeanSupport<T>>
java.lang.Object
java.beans.PropertyEditorSupport
org.promotego.editors.BeanIdEditor<T>
- Type Parameters:
T
-
- All Implemented Interfaces:
- java.beans.PropertyEditor
public class BeanIdEditor<T extends BeanSupport<T>>
- extends java.beans.PropertyEditorSupport
A parameterized property editor that maps BeanSupport objects to and from
their id's as mapped by the provided Dao. Used by controllers to map object
ID's posted by the browser to the proper object types.
- Author:
- alf
Methods inherited from class java.beans.PropertyEditorSupport |
addPropertyChangeListener, firePropertyChange, getCustomEditor, getJavaInitializationString, getSource, getTags, isPaintable, paintValue, removePropertyChangeListener, setSource, supportsCustomEditor |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
BeanIdEditor
public BeanIdEditor(Dao<T> addressDao)
getAsText
public java.lang.String getAsText()
- Specified by:
getAsText
in interface java.beans.PropertyEditor
- Overrides:
getAsText
in class java.beans.PropertyEditorSupport
getValue
public java.lang.Object getValue()
- Specified by:
getValue
in interface java.beans.PropertyEditor
- Overrides:
getValue
in class java.beans.PropertyEditorSupport
setAsText
public void setAsText(java.lang.String text)
throws java.lang.IllegalArgumentException
- Specified by:
setAsText
in interface java.beans.PropertyEditor
- Overrides:
setAsText
in class java.beans.PropertyEditorSupport
- Throws:
java.lang.IllegalArgumentException
setValue
public void setValue(java.lang.Object value)
- Specified by:
setValue
in interface java.beans.PropertyEditor
- Overrides:
setValue
in class java.beans.PropertyEditorSupport
Copyright © 2007. All Rights Reserved.