org.springframework.binding.convert.support
Class ConverterPropertyEditorAdapter
java.lang.Object
java.beans.PropertyEditorSupport
org.springframework.binding.convert.support.ConverterPropertyEditorAdapter
- All Implemented Interfaces:
- java.beans.PropertyEditor
public class ConverterPropertyEditorAdapter
- extends java.beans.PropertyEditorSupport
Adapts a Converter to the PropertyEditor interface.
Note: with a converter, only forward conversion from-string-to-value is supported. Value-to-string conversion is not
supported. If you need this capability, use a Formatter with a FormatterPropertyEditor adapter.
- Author:
- Keith Donald
- See Also:
Formatter
,
FormatterPropertyEditor
Method Summary |
java.lang.String |
getAsText()
|
java.lang.Class |
getTargetClass()
Returns the type strings will be converted to. |
void |
setAsText(java.lang.String text)
|
Methods inherited from class java.beans.PropertyEditorSupport |
addPropertyChangeListener, firePropertyChange, getCustomEditor, getJavaInitializationString, getSource, getTags, getValue, isPaintable, paintValue, removePropertyChangeListener, setSource, setValue, supportsCustomEditor |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ConverterPropertyEditorAdapter
public ConverterPropertyEditorAdapter(ConversionExecutor conversionExecutor)
- Adapt given conversion executor to the PropertyEditor contract.
getTargetClass
public java.lang.Class getTargetClass()
- Returns the type strings will be converted to.
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
getAsText
public java.lang.String getAsText()
- Specified by:
getAsText
in interface java.beans.PropertyEditor
- Overrides:
getAsText
in class java.beans.PropertyEditorSupport
Copyright � 2004-2007. All Rights Reserved.