Interface TypeConverter<T>

Type Parameters:
T - Converts Strings into the given type T.
All Known Implementing Classes:
EnumConverter, TypeConverters.BigDecimalConverter, TypeConverters.BigIntegerConverter, TypeConverters.BooleanConverter, TypeConverters.ByteArrayConverter, TypeConverters.ByteConverter, TypeConverters.CharacterConverter, TypeConverters.CharArrayConverter, TypeConverters.CharsetConverter, TypeConverters.ClassConverter, TypeConverters.DoubleConverter, TypeConverters.FileConverter, TypeConverters.FloatConverter, TypeConverters.IntegerConverter, TypeConverters.LevelConverter, TypeConverters.LongConverter, TypeConverters.PatternConverter, TypeConverters.SecurityProviderConverter, TypeConverters.ShortConverter, TypeConverters.StringConverter, TypeConverters.UriConverter, TypeConverters.UrlConverter

public interface TypeConverter<T>

Interface for doing automatic String conversion to a specific type.

2.1 Moved to the convert package.

Method Summary
 T convert(String s)
          Converts a String to a given type.

Method Detail


T convert(String s)
          throws Exception
Converts a String to a given type.

s - the String to convert. Cannot be null.
the converted object.
Exception - thrown when a conversion error occurs

Copyright © 1999-2015 Apache Software Foundation. All Rights Reserved.
Apache Logging, Apache Log4j, Log4j, Apache, the Apache feather logo, the Apache Logging project logo, and the Apache Log4j logo are trademarks of The Apache Software Foundation.