jodd.bean.converters
Class StringArrayConverter

java.lang.Object
  extended byjodd.bean.converters.StringArrayConverter
All Implemented Interfaces:
Converter

public class StringArrayConverter
extends java.lang.Object
implements Converter

Converts given object to String[]. If object is an array than it is converted to String[] array. If object is not an array, new String[] array will be created with one element only: String of the given object.


Constructor Summary
StringArrayConverter()
           
 
Method Summary
 java.lang.Object convert(java.lang.Object value)
          Converts object received as parameter into object of another class.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

StringArrayConverter

public StringArrayConverter()
Method Detail

convert

public java.lang.Object convert(java.lang.Object value)
Description copied from interface: Converter
Converts object received as parameter into object of another class. For example, in a IntegerConverter implementation of this interface, this method should convert all objects into Integer object. Conversion has to be done correctly, with investigation of given object.

If conversion is not possible, and IllegalParameterException should be thrown.

Specified by:
convert in interface Converter
Parameters:
value - object to convert from
Returns:
resulting object


Jodd v0.24.5 Javadoc