it.openutils.web.spring
Class EasyDoubleCustomEditor

java.lang.Object
  extended by java.beans.PropertyEditorSupport
      extended by org.springframework.beans.propertyeditors.CustomNumberEditor
          extended by it.openutils.web.spring.EasyDoubleCustomEditor
All Implemented Interfaces:
java.beans.PropertyEditor

public class EasyDoubleCustomEditor
extends org.springframework.beans.propertyeditors.CustomNumberEditor

Convenience double custom editor which allows to use both "." and "," as decimal separators.

Version:
$Revision$ ($Author$)
Author:
fgiust

Constructor Summary
EasyDoubleCustomEditor(java.lang.Class numberClass, boolean allowEmpty)
           
EasyDoubleCustomEditor(java.lang.Class numberClass, java.text.NumberFormat numberFormat, boolean allowEmpty)
           
 
Method Summary
 void setAsText(java.lang.String text)
           
 
Methods inherited from class org.springframework.beans.propertyeditors.CustomNumberEditor
getAsText
 
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
 

Constructor Detail

EasyDoubleCustomEditor

public EasyDoubleCustomEditor(java.lang.Class numberClass,
                              boolean allowEmpty)
                       throws java.lang.IllegalArgumentException
Parameters:
numberClass -
allowEmpty -
Throws:
java.lang.IllegalArgumentException

EasyDoubleCustomEditor

public EasyDoubleCustomEditor(java.lang.Class numberClass,
                              java.text.NumberFormat numberFormat,
                              boolean allowEmpty)
                       throws java.lang.IllegalArgumentException
Parameters:
numberClass -
numberFormat -
allowEmpty -
Throws:
java.lang.IllegalArgumentException
Method Detail

setAsText

public void setAsText(java.lang.String text)
               throws java.lang.IllegalArgumentException
Specified by:
setAsText in interface java.beans.PropertyEditor
Overrides:
setAsText in class org.springframework.beans.propertyeditors.CustomNumberEditor
Throws:
java.lang.IllegalArgumentException
See Also:
CustomNumberEditor.setAsText(java.lang.String)


Copyright {inceptionYear}-2006 Fabrizio Giustina. All Rights Reserved.