Overview | Package | Class | Tree | Index | Help

Oracle® Coherence Java API Reference
v3.5.3
E15583-01
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.tangosol.io.pof
Class PofParser

    java.lang.Object
      com.tangosol.util.Base
          com.tangosol.io.pof.PofHelper
              com.tangosol.io.pof.PofParser

All Implemented Interfaces:
  PofConstants

    public class PofParser

extends PofHelper
implements PofConstants

A "push" parser (event-based parser) for ripping through a POF stream and delivering the contents as events to a PofHandler object.

Since:
  Coherence 3.2
Author:
  cp 2006.07.12

Nested Class Summary

Nested classes/interfaces inherited from class com.tangosol.io.pof.PofHelper
`PofHelper.ReadableEntrySetMap, PofHelper.WriteableEntrySetMap`

Field Summary

Fields inherited from class com.tangosol.io.pof.PofHelper
`BIGDECIMAL_ZERO, BINARY_EMPTY, BOOLEAN_ARRAY_EMPTY, BYTE_ARRAY_EMPTY, CHAR_ARRAY_EMPTY, COLLECTION_EMPTY, DOUBLE_ARRAY_EMPTY, FLOAT_ARRAY_EMPTY, INT_ARRAY_EMPTY, LONG_ARRAY_EMPTY, OBJECT_ARRAY_EMPTY, SHORT_ARRAY_EMPTY`

Fields inherited from interface com.tangosol.io.pof.PofConstants
`J_BIG_DECIMAL, J_BIG_INTEGER, J_BINARY, J_BOOLEAN, J_BOOLEAN_ARRAY, J_BYTE, J_BYTE_ARRAY, J_CHAR_ARRAY, J_CHARACTER, J_COLLECTION, J_DATE, J_DATETIME, J_DOUBLE, J_DOUBLE_ARRAY, J_FLOAT, J_FLOAT_ARRAY, J_INT_ARRAY, J_INTEGER, J_LONG, J_LONG_ARRAY, J_MAP, J_NULL, J_OBJECT_ARRAY, J_QUAD, J_RAW_DATE, J_RAW_DATETIME, J_RAW_DAY_TIME_INTERVAL, J_RAW_TIME, J_RAW_TIME_INTERVAL, J_RAW_YEAR_MONTH_INTERVAL, J_SHORT, J_SHORT_ARRAY, J_SPARSE_ARRAY, J_STRING, J_TIME, J_TIMESTAMP, J_USER_TYPE, MAX_DECIMAL128_SCALE, MAX_DECIMAL128_UNSCALED, MAX_DECIMAL32_SCALE, MAX_DECIMAL32_UNSCALED, MAX_DECIMAL64_SCALE, MAX_DECIMAL64_UNSCALED, MIN_DECIMAL128_SCALE, MIN_DECIMAL32_SCALE, MIN_DECIMAL64_SCALE, T_ARRAY, T_BOOLEAN, T_CHAR, T_CHAR_STRING, T_COLLECTION, T_DATE, T_DATETIME, T_DAY_TIME_INTERVAL, T_DECIMAL128, T_DECIMAL32, T_DECIMAL64, T_FLOAT128, T_FLOAT32, T_FLOAT64, T_IDENTITY, T_INT128, T_INT16, T_INT32, T_INT64, T_MAP, T_OCTET, T_OCTET_STRING, T_REFERENCE, T_SPARSE_ARRAY, T_TIME, T_TIME_INTERVAL, T_UNIFORM_ARRAY, T_UNIFORM_COLLECTION, T_UNIFORM_KEYS_MAP, T_UNIFORM_MAP, T_UNIFORM_SPARSE_ARRAY, T_UNKNOWN, T_YEAR_MONTH_INTERVAL, V_BOOLEAN_FALSE, V_BOOLEAN_TRUE, V_COLLECTION_EMPTY, V_FP_NAN, V_FP_NEG_INFINITY, V_FP_POS_INFINITY, V_INT_0, V_INT_1, V_INT_10, V_INT_11, V_INT_12, V_INT_13, V_INT_14, V_INT_15, V_INT_16, V_INT_17, V_INT_18, V_INT_19, V_INT_2, V_INT_20, V_INT_21, V_INT_22, V_INT_3, V_INT_4, V_INT_5, V_INT_6, V_INT_7, V_INT_8, V_INT_9, V_INT_NEG_1, V_REFERENCE_NULL, V_STRING_ZERO_LENGTH`

Constructor Summary
`PofParser(PofHandler handler)` Construct a POF parser that will push events to the specified handler.

Method Summary
`static void` | `main(java.lang.String[] asArg)` Unit test:
`void` | `parse(ReadBuffer.BufferInput in)` Parse a POF value that is in the passed BufferInput.
`protected void` | `parseArray(ReadBuffer.BufferInput in, int iPos)` Parse an Array from the POF stream.
`protected void` | `parseCollection(ReadBuffer.BufferInput in, int iPos)` Parse a Collection from the POF stream.
`protected void` | `parseMap(ReadBuffer.BufferInput in, int iPos)` Parse a Map from the POF stream.
`protected void` | `parseSparseArray(ReadBuffer.BufferInput in, int iPos)` Parse a Sparse Array from the POF stream.
`protected void` | `parseUniformArray(ReadBuffer.BufferInput in, int iPos)` Parse a Uniform Array from the POF stream.
`protected void` | `parseUniformCollection(ReadBuffer.BufferInput in, int iPos)` Parse a Uniform Collection from the POF stream.
`protected void` | `parseUniformKeysMap(ReadBuffer.BufferInput in, int iPos)` Parse a Uniform-Keys Map from the POF stream.
`protected void` | `parseUniformMap(ReadBuffer.BufferInput in, int iPos)` Parse a Uniform Map from the POF stream.
`protected void` | `parseUniformSparseArray(ReadBuffer.BufferInput in, int iPos)` Parse a Uniform Sparse Array from the POF stream.
`protected void` | `parseUniformValue(ReadBuffer.BufferInput in, int iPos, int nType)` Within the POF stream, parse a POF value of the specified type that is in the passed BufferInput.
`protected void` | `parseUserType(ReadBuffer.BufferInput in, int iPos, int nType)` Parse a User Type from the POF stream.
`protected void` | `parseValue(ReadBuffer.BufferInput in, int iPos)` Within the POF stream, parse a POF value that is in the passed BufferInput.

Methods inherited from class com.tangosol.io.pof.PofHelper
`calcDecimalSize, checkDate, checkDayTimeInterval, checkDecimalRange, checkElementCount, checkReferenceRange, checkTime, checkTimeInterval, checkTimeZone, checkType, checkYearMonthInterval, convertNumber, convertToDate, decodeTinyInt, encodeTinyInt, formatDate, formatTime, formatTime, getJavaTypeId, getPofTypeId, readAsBigDecimal, readAsBigInteger, readAsChar, readAsDouble, readAsFloat, readAsInt, readAsLong, readAsQuad, readBigDecimal, readBigInteger, readChar, readQuad, readRawDate, readRawTime, resizeArray, skipPackedInts, skipUniformValue, skipValue, writeBigDecimal, writeBigInteger, writeDate, writeTime`

Constructor Detail

### PofParser

    public PofParser(PofHandler handler)

  Construct a POF parser that will push events to the specified handler.

  Parameters:
    `handler` - a POF handler object

Method Detail

### parse

    public void parse(ReadBuffer.BufferInput in)

  Parse a POF value that is in the passed BufferInput.

  Parameters:
    `in` - the BufferInput to read the POF value from

### parseValue

    protected void parseValue(ReadBuffer.BufferInput in,
                              int iPos)
                       throws java.io.IOException

  Within the POF stream, parse a POF value that is in the passed BufferInput.

  Parameters:
    `in` - the BufferInput to read from
    `iPos` - the position of the value that is about to be read, which is a property index, an array index, or -1
  Throws:
    `java.io.IOException`

### parseUniformValue

    protected void parseUniformValue(ReadBuffer.BufferInput in,
                                     int iPos,
                                     int nType)
                              throws java.io.IOException

  Within the POF stream, parse a POF value of the specified type that is in the passed BufferInput.

  Parameters:
    `in` - the BufferInput to read from
    `iPos` - the position of the value that is about to be read, which is a property index, an array index, or -1
    `nType` - the Type ID to parse
  Throws:
    `java.io.IOException`

### parseUserType

    protected void parseUserType(ReadBuffer.BufferInput in,
                                 int iPos,
                                 int nType)
                          throws java.io.IOException

  Parse a User Type from the POF stream.

  Parameters:
    `in` - the BufferInput to read from
    `iPos` - the position of the value that is about to be read, which is a property index, an array index, or -1
    `nType` - the Type ID for the User Type
  Throws:
    `java.io.IOException`

### parseCollection

    protected void parseCollection(ReadBuffer.BufferInput in,
                                   int iPos)
                            throws java.io.IOException

  Parse a Collection from the POF stream.

  Parameters:
    `in` - the BufferInput to read from
    `iPos` - the position of the value that is about to be read, which is a property index, an array index, or -1
  Throws:
    `java.io.IOException`

### parseUniformCollection

    protected void parseUniformCollection(ReadBuffer.BufferInput in,
                                          int iPos)
                                   throws java.io.IOException

  Parse a Uniform Collection from the POF stream.

  Parameters:
    `in` - the BufferInput to read from
    `iPos` - the position of the value that is about to be read, which is a property index, an array index, or -1
  Throws:
    `java.io.IOException`

### parseArray

    protected void parseArray(ReadBuffer.BufferInput in,
                              int iPos)
                       throws java.io.IOException

  Parse an Array from the POF stream.

  Parameters:
    `in` - the BufferInput to read from
    `iPos` - the position of the value that is about to be read, which is a property index, an array index, or -1
  Throws:
    `java.io.IOException`

### parseUniformArray

    protected void parseUniformArray(ReadBuffer.BufferInput in,
                                     int iPos)
                              throws java.io.IOException

  Parse a Uniform Array from the POF stream.

  Parameters:
    `in` - the BufferInput to read from
    `iPos` - the position of the value that is about to be read, which is a property index, an array index, or -1
  Throws:
    `java.io.IOException`

### parseSparseArray

    protected void parseSparseArray(ReadBuffer.BufferInput in,
                                    int iPos)
                             throws java.io.IOException

  Parse a Sparse Array from the POF stream.

  Parameters:
    `in` - the BufferInput to read from
    `iPos` - the position of the value that is about to be read, which is a property index, an array index, or -1
  Throws:
    `java.io.IOException`

### parseUniformSparseArray

    protected void parseUniformSparseArray(ReadBuffer.BufferInput in,
                                           int iPos)
                                    throws java.io.IOException

  Parse a Uniform Sparse Array from the POF stream.

  Parameters:
    `in` - the BufferInput to read from
    `iPos` - the position of the value that is about to be read, which is a property index, an array index, or -1
  Throws:
    `java.io.IOException`

### parseMap

    protected void parseMap(ReadBuffer.BufferInput in,
                            int iPos)
                     throws java.io.IOException

  Parse a Map from the POF stream.

  Parameters:
    `in` - the BufferInput to read from
    `iPos` - the position of the value that is about to be read, which is a property index, an array index, or -1
  Throws:
    `java.io.IOException`

### parseUniformKeysMap

    protected void parseUniformKeysMap(ReadBuffer.BufferInput in,
                                       int iPos)
                                throws java.io.IOException

  Parse a Uniform-Keys Map from the POF stream.

  Parameters:
    `in` - the BufferInput to read from
    `iPos` - the position of the value that is about to be read, which is a property index, an array index, or -1
  Throws:
    `java.io.IOException`

### parseUniformMap

    protected void parseUniformMap(ReadBuffer.BufferInput in,
                                   int iPos)
                            throws java.io.IOException

  Parse a Uniform Map from the POF stream.

  Parameters:
    `in` - the BufferInput to read from
    `iPos` - the position of the value that is about to be read, which is a property index, an array index, or -1
  Throws:
    `java.io.IOException`

### main

    public static void main(java.lang.String[] asArg)
                     throws java.lang.Exception

  Unit test:

       java PofParser

  Parameters:
    `asArg` - command line arguments
  Throws:
    `java.lang.Exception`

Overview | Package | Class | Tree | Index | Help

Oracle® Coherence Java API Reference
v3.5.3
E15583-01
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2000, 2010, Oracle. All rights reserved.