Spring for Android

org.springframework.core.convert.converter
Interface Converter<S,T>

Type Parameters:
S - The source type
T - The target type

public interface Converter<S,T>

A converter converts a source object of type S to a target of type T. Implementations of this interface are thread-safe and can be shared.

Implementations may additionally implement ConditionalConverter.

Since:
2.0
Author:
Keith Donald
See Also:
ConditionalConverter

Method Summary
 T convert(S source)
          Convert the source of type S to target type T.
 

Method Detail

convert

T convert(S source)
Convert the source of type S to target type T.

Parameters:
source - the source object to convert, which must be an instance of S
Returns:
the converted object, which must be an instance of T
Throws:
java.lang.IllegalArgumentException - if the source could not be converted to the desired target type

Spring for Android