Class StringFormatter

java.lang.Object
ca.phon.formatter.StringFormatter
All Implemented Interfaces:
Formatter<Object>

@FormatterType(String.class) public class StringFormatter extends Object implements Formatter<Object>
Basic formatter which simply returns the given string value.
  • Constructor Details

    • StringFormatter

      public StringFormatter()
  • Method Details

    • format

      public String format(Object obj)
      Description copied from interface: Formatter
      Convert the given object into a formatted String.
      Specified by:
      format in interface Formatter<Object>
      Parameters:
      obj -
      Returns:
      formatted string
    • parse

      public Object parse(String text) throws ParseException
      Description copied from interface: Formatter
      Parse the given string into a new object instance
      Specified by:
      parse in interface Formatter<Object>
      Parameters:
      text -
      Returns:
      parsed object
      Throws:
      ParseException - if there was a problem parsing the given text