Interface StringConverter<T>

Type Parameters:
T - the class type of the parameter value to convert
All Known Implementing Classes:
BooleanStringConverter, DateStringConverter, IntegerStringConverter, StringStringConverter, URIStringConverter

public interface StringConverter<T>
Author:
Joern Muehlencord (joern@muehlencord.de)
  • Method Summary

    Modifier and Type
    Method
    Description
    <V> V
    Converter a string to a the given type
    Converter a parameter object to a string representation
  • Method Details

    • toString

      String toString(T o) throws ConverterException
      Converter a parameter object to a string representation
      Parameters:
      o - the parameter value to convert
      Returns:
      the parameter value as string
      Throws:
      ConverterException - if the conversion fails
    • fromString

      <V> V fromString(String s) throws ConverterException
      Converter a string to a the given type
      Type Parameters:
      V - the type of the converter
      Parameters:
      s - string representation of a parameter value to convert to an object
      Returns:
      the parameter value as object
      Throws:
      ConverterException - if the conversion fails