Class DataFormatter

java.lang.Object
org.wikidata.wdtk.datamodel.helpers.DataFormatter

public class DataFormatter extends Object
This class contains static methods to create string notations for values of several datatypes and classes.
Author:
Michael Günther
  • Constructor Details

    • DataFormatter

      public DataFormatter()
  • Method Details

    • formatTimeISO8601

      public static String formatTimeISO8601(TimeValue value)
      Returns a representation of the date from the value attributes as ISO 8601 encoding.
      Parameters:
      value -
      Returns:
      ISO 8601 value (String)
    • formatBigDecimal

      public static String formatBigDecimal(BigDecimal number)
      Returns a signed string representation of the given number.
      Parameters:
      number -
      Returns:
      String for BigDecimal value