java.lang.Object
org.elasticsearch.xpack.core.analytics.mapper.TDigestParser

public class TDigestParser extends Object
  • Field Details

  • Constructor Details

    • TDigestParser

      public TDigestParser()
  • Method Details

    • parse

      public static TDigestParser.ParsedTDigest parse(String mappedFieldName, org.elasticsearch.xcontent.XContentParser parser, BiFunction<org.elasticsearch.xcontent.XContentLocation,String,RuntimeException> documentParsingExceptionProvider, TDigestParser.ParsingExceptionProvider parsingExceptionProvider) throws IOException
      Parses an XContent object into a histogram. The parser is expected to point at the next token after XContentParser.Token.START_OBJECT.
      Parameters:
      mappedFieldName - the name of the field being parsed, used for error messages
      parser - the parser to use
      documentParsingExceptionProvider - factory function for generating document parsing exceptions. Required for visibility.
      Returns:
      the parsed histogram
      Throws:
      IOException
    • ensureExpectedToken

      public static void ensureExpectedToken(org.elasticsearch.xcontent.XContentParser.Token expected, org.elasticsearch.xcontent.XContentParser.Token actual, org.elasticsearch.xcontent.XContentParser parser, TDigestParser.ParsingExceptionProvider parsingExceptionProvider) throws IOException
      Throws:
      IOException