java.lang.Object
tools.jackson.core.JsonParser
tools.jackson.core.base.ParserMinimalBase
tools.jackson.core.base.ParserBase
tools.jackson.dataformat.avro.AvroParser
tools.jackson.dataformat.avro.deser.AvroParserImpl
All Implemented Interfaces:
Closeable, AutoCloseable, tools.jackson.core.Versioned
Direct Known Subclasses:
ApacheAvroParserImpl, JacksonAvroParserImpl

public abstract class AvroParserImpl extends AvroParser
Implementation base class that exposes additional internal API to be used as callbacks by AvroReadContext implementations.
  • Nested Class Summary

    Nested classes/interfaces inherited from class tools.jackson.core.JsonParser

    tools.jackson.core.JsonParser.NumberType, tools.jackson.core.JsonParser.NumberTypeFP
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    protected int
    Index of the union branch that was followed to reach the current token.
    protected int
    Index of the enum that was read as the current token.

    Fields inherited from class tools.jackson.dataformat.avro.AvroParser

    _avroContext, _formatFeatures, _rootSchema, _streamReadContext, AVRO_READ_CAPABILITIES

    Fields inherited from class tools.jackson.core.base.ParserBase

    _binaryValue, _byteArrayBuilder, _currInputProcessed, _currInputRow, _currInputRowStart, _expLength, _fractLength, _inputEnd, _inputPtr, _intLength, _numberBigDecimal, _numberBigInt, _numberDouble, _numberFloat, _numberInt, _numberIsNaN, _numberLong, _numberNegative, _numberString, _numTypesValid, _textBuffer, _tokenInputCol, _tokenInputRow, _tokenInputTotal

    Fields inherited from class tools.jackson.core.base.ParserMinimalBase

    _closed, _currToken, _ioContext, _lastClearedToken, _objectReadContext, _streamReadConstraints, _streamReadFeatures, _tokenCount, _trackMaxTokenCount, BD_MAX_INT, BD_MAX_LONG, BD_MIN_INT, BD_MIN_LONG, BI_MAX_INT, BI_MAX_LONG, BI_MIN_INT, BI_MIN_LONG, CHAR_NULL, INT_0, INT_9, INT_APOS, INT_ASTERISK, INT_BACKSLASH, INT_COLON, INT_COMMA, INT_CR, INT_e, INT_E, INT_HASH, INT_LBRACKET, INT_LCURLY, INT_LF, INT_MINUS, INT_PERIOD, INT_PLUS, INT_QUOTE, INT_RBRACKET, INT_RCURLY, INT_RS, INT_SLASH, INT_SPACE, INT_TAB, MAX_BYTE_I, MAX_INT_D, MAX_INT_L, MAX_LONG_D, MAX_SHORT_I, MIN_BYTE_I, MIN_INT_D, MIN_INT_L, MIN_LONG_D, MIN_SHORT_I, NO_BYTES, NO_INTS, NR_BIGDECIMAL, NR_BIGINT, NR_DOUBLE, NR_FLOAT, NR_INT, NR_LONG, NR_UNKNOWN, STREAM_READ_FEATURE_DEFAULTS

    Fields inherited from class tools.jackson.core.JsonParser

    DEFAULT_READ_CAPABILITIES
  • Constructor Summary

    Constructors
    Modifier
    Constructor
    Description
    protected
    AvroParserImpl(tools.jackson.core.ObjectReadContext readCtxt, tools.jackson.core.io.IOContext ioCtxt, int parserFeatures, int avroFeatures, AvroSchema schema)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    protected final void
     
    final void
     
    final int
     
    abstract boolean
     
    void
     
    protected final void
     
    protected final void
     
    protected final void
     
    protected final void
     
    protected final void
     
    protected final void
     
    abstract long
     
    abstract long
     
    abstract tools.jackson.core.JsonToken
     
    abstract tools.jackson.core.JsonToken
     
    tools.jackson.core.JsonToken
    decodeBytesDecimal(int scale)
     
    abstract tools.jackson.core.JsonToken
     
    abstract int
     
    abstract tools.jackson.core.JsonToken
    decodeFixed(int size)
     
    tools.jackson.core.JsonToken
    decodeFixedDecimal(int scale, int size)
     
    abstract tools.jackson.core.JsonToken
     
    abstract int
     
    abstract int
     
    abstract tools.jackson.core.JsonToken
     
    abstract long
     
    abstract tools.jackson.core.JsonToken
     
    abstract String
     
    abstract long
     
    abstract long
     
    abstract void
     
    abstract tools.jackson.core.JsonToken
     
    final int
     
    final float
     
    final tools.jackson.core.JsonParser.NumberType
     
    tools.jackson.core.JsonParser.NumberTypeFP
     
    final Number
     
    final Number
     
    long
    Returns the remaining number of elements in the current block of a map or array
    final boolean
     
    final boolean
     
     
    boolean
    nextName(tools.jackson.core.SerializableString sstr)
     
    int
    nextNameMatch(tools.jackson.core.sym.PropertyNameMatcher matcher)
     
    abstract String
     
    tools.jackson.core.JsonToken
     
    final void
     
    protected final tools.jackson.core.JsonToken
    setBytes(byte[] b)
     
    protected final tools.jackson.core.JsonToken
    setNumber(double v)
     
    protected final tools.jackson.core.JsonToken
    setNumber(float v)
     
    protected final tools.jackson.core.JsonToken
    setNumber(int v)
     
    protected final tools.jackson.core.JsonToken
    setNumber(long v)
     
    protected abstract tools.jackson.core.JsonToken
     
    abstract long
     
    abstract void
     
    abstract void
     
    void
     
    abstract void
     
    abstract void
    skipFixed(int size)
     
    void
    skipFixedDecimal(int size)
     
    abstract void
     
    abstract void
     
    abstract void
     
    abstract long
     
    abstract void
     
    final void
    Skip to the end of the current structure (array/map/object); This is different from skipMap() and skipArray() because it operates at the parser level instead of at the decoder level and advances the parsing context in addition to consuming the data from the input.

    Methods inherited from class tools.jackson.core.base.ParserBase

    _contentReference, _contentReferenceRedacted, _convertBigDecimalToBigInteger, _decodeBase64Escape, _decodeBase64Escape, _decodeEscaped, _eofAsNextChar, _getBigDecimal, _getBigInteger, _getByteArrayBuilder, _getNumberDouble, _getNumberFloat, _growNameDecodeBuffer, _handleBase64MissingPadding, _handleEOF, _releaseBuffers, _reportInvalidBase64Char, _reportInvalidBase64Char, getBigIntegerValue, getDecimalValue, getDoubleValue, getIntValue, getLongValue, getNumberValueDeferred, getTokenCharacterOffset, getTokenColumnNr, getTokenLineNr, growArrayBy, reset, resetAsNaN, resetFloat, resetInt

    Methods inherited from class tools.jackson.core.base.ParserMinimalBase

    _constructInputCoercion, _constructNotNumericType, _currentLocationMinusOne, _decodeBase64, _getCharDesc, _hasTextualNull, _longIntegerDesc, _longNumberDesc, _nullSafeUpdateToken, _reportBadInputStream, _reportBadReader, _reportError, _reportError, _reportError, _reportError, _reportInvalidEOF, _reportInvalidEOF, _reportInvalidEOFInValue, _reportInvalidNumber, _reportInvalidSpace, _reportInvalidUTF8Surrogate, _reportMissingRootWS, _reportOverflowByte, _reportOverflowInt, _reportOverflowInt, _reportOverflowInt, _reportOverflowLong, _reportOverflowLong, _reportOverflowLong, _reportOverflowShort, _reportUnexpectedChar, _reportUnexpectedNumberChar, _throwInternal, _updateToken, _updateTokenToNA, _updateTokenToNull, _wrapIOFailure, clearCurrentToken, currentNameMatch, currentToken, currentTokenCount, currentTokenId, finishToken, getBooleanValue, getByteValue, getLastClearedToken, getShortValue, getValueAsBoolean, getValueAsDouble, getValueAsInt, getValueAsInt, getValueAsLong, getValueAsLong, getValueAsString, getValueAsString, hasCurrentToken, hasToken, hasTokenId, isClosed, isEnabled, isExpectedNumberIntToken, isExpectedStartArrayToken, isExpectedStartObjectToken, nextValue, objectReadContext, readValueAs, readValueAs, readValueAs, readValueAsTree, skipChildren, streamReadConstraints, streamReadFeatures

    Methods inherited from class tools.jackson.core.JsonParser

    _constructReadException, _constructReadException, _constructReadException, _constructReadException, _constructReadException, _constructReadException, _reportUnsupportedOperation, canParseAsync, canReadObjectId, getBinaryValue, getObjectId, getText, getTextCharacters, getTextLength, getTextOffset, getValueAsBoolean, getValueAsDouble, nextBooleanValue, nextIntValue, nextLongValue, nonBlockingInputFeeder, readBinaryValue, readBinaryValue, readString, releaseBuffered, releaseBuffered

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • _branchIndex

      protected int _branchIndex
      Index of the union branch that was followed to reach the current token. This is cleared when the next token is read.
    • _enumIndex

      protected int _enumIndex
      Index of the enum that was read as the current token. This is cleared when the next token is read.
  • Constructor Details

    • AvroParserImpl

      protected AvroParserImpl(tools.jackson.core.ObjectReadContext readCtxt, tools.jackson.core.io.IOContext ioCtxt, int parserFeatures, int avroFeatures, AvroSchema schema)
  • Method Details

    • close

      public void close()
      Specified by:
      close in interface AutoCloseable
      Specified by:
      close in interface Closeable
      Overrides:
      close in class tools.jackson.core.base.ParserBase
    • nextToken

      public tools.jackson.core.JsonToken nextToken() throws tools.jackson.core.JacksonException
      Specified by:
      nextToken in class tools.jackson.core.JsonParser
      Throws:
      tools.jackson.core.JacksonException
    • skipValue

      public final void skipValue() throws tools.jackson.core.JacksonException
      Skip to the end of the current structure (array/map/object); This is different from skipMap() and skipArray() because it operates at the parser level instead of at the decoder level and advances the parsing context in addition to consuming the data from the input.
      Throws:
      tools.jackson.core.JacksonException - If there was an issue advancing through the underlying data stream
    • nextName

      public String nextName() throws tools.jackson.core.JacksonException
      Overrides:
      nextName in class tools.jackson.core.base.ParserMinimalBase
      Throws:
      tools.jackson.core.JacksonException
    • nextName

      public boolean nextName(tools.jackson.core.SerializableString sstr) throws tools.jackson.core.JacksonException
      Overrides:
      nextName in class tools.jackson.core.base.ParserMinimalBase
      Throws:
      tools.jackson.core.JacksonException
    • nextNameMatch

      public int nextNameMatch(tools.jackson.core.sym.PropertyNameMatcher matcher) throws tools.jackson.core.JacksonException
      Overrides:
      nextNameMatch in class tools.jackson.core.base.ParserMinimalBase
      Throws:
      tools.jackson.core.JacksonException
    • nextStringValue

      public abstract String nextStringValue() throws tools.jackson.core.JacksonException
      Overrides:
      nextStringValue in class tools.jackson.core.JsonParser
      Throws:
      tools.jackson.core.JacksonException
    • _initSchema

      public final void _initSchema(AvroSchema schema) throws tools.jackson.core.JacksonException
      Specified by:
      _initSchema in class AvroParser
      Throws:
      tools.jackson.core.JacksonException
    • isNaN

      public final boolean isNaN()
      Overrides:
      isNaN in class tools.jackson.core.base.ParserBase
    • getNumberValue

      public final Number getNumberValue() throws tools.jackson.core.JacksonException
      Overrides:
      getNumberValue in class tools.jackson.core.base.ParserBase
      Throws:
      tools.jackson.core.JacksonException
    • getNumberValueExact

      public final Number getNumberValueExact() throws tools.jackson.core.JacksonException
      Overrides:
      getNumberValueExact in class tools.jackson.core.base.ParserBase
      Throws:
      tools.jackson.core.JacksonException
    • getNumberType

      public final tools.jackson.core.JsonParser.NumberType getNumberType() throws tools.jackson.core.JacksonException
      Overrides:
      getNumberType in class tools.jackson.core.base.ParserBase
      Throws:
      tools.jackson.core.JacksonException
    • getNumberTypeFP

      public tools.jackson.core.JsonParser.NumberTypeFP getNumberTypeFP() throws tools.jackson.core.JacksonException
      Overrides:
      getNumberTypeFP in class tools.jackson.core.base.ParserMinimalBase
      Throws:
      tools.jackson.core.JacksonException
    • getFloatValue

      public final float getFloatValue() throws tools.jackson.core.JacksonException
      Overrides:
      getFloatValue in class tools.jackson.core.base.ParserBase
      Throws:
      tools.jackson.core.JacksonException
    • _checkNumericValue

      protected final void _checkNumericValue() throws tools.jackson.core.JacksonException
      Throws:
      tools.jackson.core.JacksonException
    • convertNumberToInt

      protected final void convertNumberToInt() throws tools.jackson.core.JacksonException
      Overrides:
      convertNumberToInt in class tools.jackson.core.base.ParserBase
      Throws:
      tools.jackson.core.JacksonException
    • convertNumberToLong

      protected final void convertNumberToLong() throws tools.jackson.core.JacksonException
      Overrides:
      convertNumberToLong in class tools.jackson.core.base.ParserBase
      Throws:
      tools.jackson.core.JacksonException
    • convertNumberToBigInteger

      protected final void convertNumberToBigInteger() throws tools.jackson.core.JacksonException
      Overrides:
      convertNumberToBigInteger in class tools.jackson.core.base.ParserBase
      Throws:
      tools.jackson.core.JacksonException
    • convertNumberToFloat

      protected final void convertNumberToFloat() throws tools.jackson.core.JacksonException
      Overrides:
      convertNumberToFloat in class tools.jackson.core.base.ParserBase
      Throws:
      tools.jackson.core.JacksonException
    • convertNumberToDouble

      protected final void convertNumberToDouble() throws tools.jackson.core.JacksonException
      Overrides:
      convertNumberToDouble in class tools.jackson.core.base.ParserBase
      Throws:
      tools.jackson.core.JacksonException
    • convertNumberToBigDecimal

      protected final void convertNumberToBigDecimal() throws tools.jackson.core.JacksonException
      Overrides:
      convertNumberToBigDecimal in class tools.jackson.core.base.ParserBase
      Throws:
      tools.jackson.core.JacksonException
    • checkInputEnd

      public abstract boolean checkInputEnd() throws IOException
      Throws:
      IOException
    • getRemainingElements

      public long getRemainingElements()
      Returns the remaining number of elements in the current block of a map or array
    • decodeIntToken

      public abstract tools.jackson.core.JsonToken decodeIntToken() throws IOException
      Throws:
      IOException
    • decodeInt

      public abstract int decodeInt() throws IOException
      Throws:
      IOException
    • skipInt

      public abstract void skipInt() throws IOException
      Throws:
      IOException
    • decodeLongToken

      public abstract tools.jackson.core.JsonToken decodeLongToken() throws IOException
      Throws:
      IOException
    • decodeLong

      public abstract long decodeLong() throws IOException
      Throws:
      IOException
    • skipLong

      public abstract void skipLong() throws IOException
      Throws:
      IOException
    • decodeFloat

      public abstract tools.jackson.core.JsonToken decodeFloat() throws IOException
      Throws:
      IOException
    • skipFloat

      public abstract void skipFloat() throws IOException
      Throws:
      IOException
    • decodeDouble

      public abstract tools.jackson.core.JsonToken decodeDouble() throws IOException
      Throws:
      IOException
    • skipDouble

      public abstract void skipDouble() throws IOException
      Throws:
      IOException
    • decodeStringToken

      public abstract tools.jackson.core.JsonToken decodeStringToken() throws IOException
      Throws:
      IOException
    • decodeString

      public abstract void decodeString() throws IOException
      Throws:
      IOException
    • skipString

      public abstract void skipString() throws IOException
      Throws:
      IOException
    • decodeBytes

      public abstract tools.jackson.core.JsonToken decodeBytes() throws IOException
      Throws:
      IOException
    • skipBytes

      public abstract void skipBytes() throws IOException
      Throws:
      IOException
    • decodeFixed

      public abstract tools.jackson.core.JsonToken decodeFixed(int size) throws IOException
      Throws:
      IOException
    • skipFixed

      public abstract void skipFixed(int size) throws IOException
      Throws:
      IOException
    • decodeArrayStart

      public abstract long decodeArrayStart() throws IOException
      Throws:
      IOException
    • decodeArrayNext

      public abstract long decodeArrayNext() throws IOException
      Throws:
      IOException
    • skipArray

      public abstract long skipArray() throws IOException
      Returns:
      Either 0, in which case all entries have been successfully skipped; or positive non-zero number to indicate elements that caller has to skip
      Throws:
      IOException
    • decodeMapKey

      public abstract String decodeMapKey() throws IOException
      Throws:
      IOException
    • decodeMapStart

      public abstract long decodeMapStart() throws IOException
      Throws:
      IOException
    • decodeMapNext

      public abstract long decodeMapNext() throws IOException
      Throws:
      IOException
    • skipMap

      public abstract long skipMap() throws IOException
      Returns:
      Either 0, in which case all entries have been successfully skipped; or positive non-zero number to indicate map entries that caller has to skip
      Throws:
      IOException
    • decodeBoolean

      public abstract tools.jackson.core.JsonToken decodeBoolean() throws IOException
      Throws:
      IOException
    • skipBoolean

      public abstract void skipBoolean() throws IOException
      Throws:
      IOException
    • decodeIndex

      public abstract int decodeIndex() throws IOException
      Throws:
      IOException
    • decodeEnum

      public abstract int decodeEnum() throws IOException
      Throws:
      IOException
    • decodeBytesDecimal

      public tools.jackson.core.JsonToken decodeBytesDecimal(int scale) throws IOException
      Throws:
      IOException
    • skipBytesDecimal

      public void skipBytesDecimal() throws IOException
      Throws:
      IOException
    • decodeFixedDecimal

      public tools.jackson.core.JsonToken decodeFixedDecimal(int scale, int size) throws IOException
      Throws:
      IOException
    • skipFixedDecimal

      public void skipFixedDecimal(int size) throws IOException
      Throws:
      IOException
    • branchIndex

      public final int branchIndex()
    • enumIndex

      public final int enumIndex()
    • isRecord

      public final boolean isRecord()
    • setAvroContext

      public final void setAvroContext(AvroReadContext ctxt)
    • setBytes

      protected final tools.jackson.core.JsonToken setBytes(byte[] b)
    • setNumber

      protected final tools.jackson.core.JsonToken setNumber(int v)
    • setNumber

      protected final tools.jackson.core.JsonToken setNumber(long v)
    • setNumber

      protected final tools.jackson.core.JsonToken setNumber(float v)
    • setNumber

      protected final tools.jackson.core.JsonToken setNumber(double v)
    • setString

      protected abstract tools.jackson.core.JsonToken setString(String str) throws IOException
      Throws:
      IOException