Enum Class PointFormatter

java.lang.Object
java.lang.Enum<PointFormatter>
org.springframework.data.geo.format.PointFormatter
All Implemented Interfaces:
Serializable, Comparable<PointFormatter>, Constable, org.springframework.core.convert.converter.Converter<String,Point>, org.springframework.format.Formatter<Point>, org.springframework.format.Parser<Point>, org.springframework.format.Printer<Point>

public enum PointFormatter extends Enum<PointFormatter> implements org.springframework.core.convert.converter.Converter<String,Point>, org.springframework.format.Formatter<Point>
Converter to parse two comma-separated doubles into a Point.
Author:
Oliver Gierke
  • Enum Constant Details

  • Field Details

    • CONVERTIBLE

      public static final org.springframework.core.convert.converter.GenericConverter.ConvertiblePair CONVERTIBLE
  • Method Details

    • values

      public static PointFormatter[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static PointFormatter valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null
    • convert

      @NonNull public Point convert(String source)
      Specified by:
      convert in interface org.springframework.core.convert.converter.Converter<String,Point>
    • print

      public String print(Point point, Locale locale)
      Specified by:
      print in interface org.springframework.format.Printer<Point>
    • parse

      public Point parse(String text, Locale locale) throws ParseException
      Specified by:
      parse in interface org.springframework.format.Parser<Point>
      Throws:
      ParseException