de.smartics.properties.spi.core.convert
Class BeanUtilsPropertyValueConverter

Package class diagram package BeanUtilsPropertyValueConverter
java.lang.Object
  extended by de.smartics.properties.spi.core.convert.BeanUtilsPropertyValueConverter
All Implemented Interfaces:
PropertyValueConverter, Serializable

public final class BeanUtilsPropertyValueConverter
     
     
extends Object
implements PropertyValueConverter

Converter of property values to and from Strings using Apache's commons-beanutils.

See Also:
Serialized Form

Constructor Summary
BeanUtilsPropertyValueConverter()
           
 
Method Summary
 Object convert(PropertyDescriptor descriptor, Object value)
          Converts, if necessary, the given value to the target type defined by the descriptor.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BeanUtilsPropertyValueConverter

public BeanUtilsPropertyValueConverter()
Method Detail

convert

public Object convert(PropertyDescriptor descriptor,
                      Object value)
               throws PropertyValueConversionException
Description copied from interface: PropertyValueConverter
Converts, if necessary, the given value to the target type defined by the descriptor.

Specified by:
convert in interface PropertyValueConverter
Parameters:
descriptor - the descriptor of the property.
value - the value to be converted according to the rules defined by the descriptor.
Returns:
the converted value.
Throws:
PropertyValueConversionException - if the value cannot be converted from String to the target type.


Copyright © 2012-2013 Kronseder & Reiner GmbH - smartics. All Rights Reserved.