Interface DocumentSizeObserver


public interface DocumentSizeObserver
An interface to allow wrapping an XContentParser and observe the events emitted while parsing A default implementation returns a noop DocumentSizeObserver
  • Field Details

  • Method Details

    • wrapParser

      XContentParser wrapParser(XContentParser xContentParser)
      Decorates a provided xContentParser with additional logic (gather some state).
      Parameters:
      xContentParser - to be decorated
      Returns:
      a decorator xContentParser
    • normalisedBytesParsed

      long normalisedBytesParsed()
      Returns the state gathered during parsing
      Returns:
      a number representing a state parsed