org.loom.converter
Class CharacterConverter

java.lang.Object
  extended by org.loom.converter.AbstractConverter
      extended by org.loom.converter.AbstractStringConverter
          extended by org.loom.converter.AbstractSimpleConverter
              extended by org.loom.converter.CharacterConverter
All Implemented Interfaces:
Converter, LocaleUnawareConverter, FormInputDecorator

public class CharacterConverter
extends AbstractSimpleConverter
implements LocaleUnawareConverter


Field Summary
 
Fields inherited from class org.loom.converter.AbstractConverter
convertedClass, cssClass
 
Constructor Summary
CharacterConverter()
           
 
Method Summary
 void decorate(FormInputTag t)
          Add CSS class extracted from this converter return type (number, string, file) to the tag.
 java.lang.Object getAsObject(java.lang.String text)
          Perform the conversion.
 java.lang.String getAsTextImpl(java.lang.Object value, MessagesRepository repository)
          This method is the getAsText implementation, and has the guarantee that the value is not null
 
Methods inherited from class org.loom.converter.AbstractSimpleConverter
getAsObjectImpl
 
Methods inherited from class org.loom.converter.AbstractStringConverter
getAsObject, getAsText, getNullValue, setNullValue
 
Methods inherited from class org.loom.converter.AbstractConverter
addErrorMessage, getConvertedClass, getCssClass, setConvertedClass, setCssClass
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.loom.converter.Converter
getAsObject, getAsText, getConvertedClass
 

Constructor Detail

CharacterConverter

public CharacterConverter()
Method Detail

getAsTextImpl

public java.lang.String getAsTextImpl(java.lang.Object value,
                                      MessagesRepository repository)
Description copied from class: AbstractStringConverter
This method is the getAsText implementation, and has the guarantee that the value is not null

Overrides:
getAsTextImpl in class AbstractStringConverter

getAsObject

public java.lang.Object getAsObject(java.lang.String text)
Description copied from interface: LocaleUnawareConverter
Perform the conversion. If the input data is not valid, will throw a RuntimeException.

Specified by:
getAsObject in interface LocaleUnawareConverter
Specified by:
getAsObject in class AbstractSimpleConverter

decorate

public void decorate(FormInputTag t)
Description copied from class: AbstractConverter
Add CSS class extracted from this converter return type (number, string, file) to the tag.

Specified by:
decorate in interface FormInputDecorator
Overrides:
decorate in class AbstractConverter