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 ValidatingPofHandler.Complex

    java.lang.Object
      com.tangosol.util.Base
          com.tangosol.io.pof.ValidatingPofHandler.Complex

Direct Known Subclasses:
  ValidatingPofHandler.ComplexMap

Enclosing class:
  ValidatingPofHandler

    public class ValidatingPofHandler.Complex

extends Base

A Complex object represents the current complex data structure in the POF stream.

Constructor Summary
`ValidatingPofHandler.Complex(ValidatingPofHandler.Complex complexCurrent, int cElements, boolean fContiguous)` Construct a Complex object for a data collection or user type.
`ValidatingPofHandler.Complex(ValidatingPofHandler.Complex complexCurrent, int cElements, boolean fContiguous, int nUniformTypeId)` Construct a Complex object for a uniformly-typed data collection.

Method Summary
`void` | `checkPosition(int iPos)` Notify the Complex object that a value has been encountered.
`int` | `getElementCount()` Obtain the total element count.
`int` | `getLastPosition()` Obtain the last known position, which is the index (or property number) of the most recent value.
`int` | `getNextPosition()` For complex values with contiguous values, obtain the next position.
`int` | `getUniformType()` If the object encoding is using uniform encoding, obtain the type id of the uniform type.
`boolean` | `isContiguous()` Determine if the elements are contiguous.
`boolean` | `isUniform()` Determine if the object encoding within the Complex type is uniform.
`ValidatingPofHandler.Complex` | `pop()` Pop this Complex object off the stack, returning the outer Complex object or null if there is none.

Constructor Detail

### ValidatingPofHandler.Complex

    public ValidatingPofHandler.Complex(ValidatingPofHandler.Complex complexCurrent,
                                        int cElements,
                                        boolean fContiguous)

  Construct a Complex object for a data collection or user type.

  Parameters:
    `complexCurrent` - the current Complex object or null
    `cElements` - the total (or maximum) number of elements
    `fContiguous` - true if the elements are contiguous

### ValidatingPofHandler.Complex

    public ValidatingPofHandler.Complex(ValidatingPofHandler.Complex complexCurrent,
                                        int cElements,
                                        boolean fContiguous,
                                        int nUniformTypeId)

  Construct a Complex object for a uniformly-typed data collection.

  Parameters:
    `complexCurrent` - the current Complex object or null
    `cElements` - the total (or maximum) number of elements
    `fContiguous` - true if the elements are contiguous
    `nUniformTypeId` - the type identifier of the uniform type

Method Detail

### checkPosition

    public void checkPosition(int iPos)

  Notify the Complex object that a value has been encountered.

  Parameters:
    `iPos` - the position that accomponied the value

### getLastPosition

    public int getLastPosition()

  Obtain the last known position, which is the index (or property number) of the most recent value.

  Returns:
    the previous position that was reported to checkPosition()

### getNextPosition

    public int getNextPosition()

  For complex values with contiguous values, obtain the next position.

  Returns:
    the next position

### getElementCount

    public int getElementCount()

  Obtain the total element count. The element count is not known (i.e. it is not limited) for user types. For sparse types, the element count is the maximum number of values in the sparse value, which is often greater than the actual number of values. For Map types, the number of values is two times the element count (since each element has a key and a value).

  Returns:
    the maximum element count

### isContiguous

    public boolean isContiguous()

  Determine if the elements are contiguous.

  Returns:
    true for all complex types except user and sparse types

### isUniform

    public boolean isUniform()

  Determine if the object encoding within the Complex type is uniform.

  Returns:
    true iff values within the Complex type are of a uniform type and are encoded uniformly

### getUniformType

    public int getUniformType()

  If the object encoding is using uniform encoding, obtain the type id of the uniform type.

  Returns:
    the type id used for the uniform encoding

### pop

    public ValidatingPofHandler.Complex pop()

  Pop this Complex object off the stack, returning the outer Complex object or null if there is none.

  Returns:
    the outer Complex object or null if there is none

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.