Package org.apache.uima.cas.impl

# Class CasSeqAddrMaps

java.lang.Object
org.apache.uima.cas.impl.CasSeqAddrMaps

public class CasSeqAddrMaps extends Object
Used by Binary serialization form 4 and 6 Manage the conversion of FSs to relative sequential index number, and back Manage the difference in two type systems both size of the FSs and handling excluded types During serialization, these maps are constructed before serialization. During deserialization, these maps are constructed while things are being deserialized, and then used in a "fixup" call at the end. This allows for forward references. For delta deserialization, the base part of these maps (for below-the-line) is constructed by scanning up to the mark.

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `CasSeqAddrMaps()`
  `CasSeqAddrMaps(List<TOP> tgtSeq2SrcFs, org.apache.uima.internal.util.rb_trees.Int2IntRBT srcAddr2TgtSeq)`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `void`
  `addItemId(TOP srcFs, int tgtId, boolean inTarget)`
  Add a new FS id - done during prescan of source during serialization Must call in heap scan order
  `void`
  `addSrcFsForTgt(TOP srcFs, boolean inSrc)`
  Called during deserialize to incrementally add
  `int`
  `getNumberSrcFss()`
  `TOP`
  `getSrcFsFromTgtSeq(int seq)`
  `int`
  `getTgtSeqFromSrcAddr(int itemAddr)`

  ### Methods inherited from class java.lang.Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- ## Constructor Details

  - ### CasSeqAddrMaps

    public CasSeqAddrMaps()

  - ### CasSeqAddrMaps

    public CasSeqAddrMaps(List<TOP> tgtSeq2SrcFs, org.apache.uima.internal.util.rb_trees.Int2IntRBT srcAddr2TgtSeq)

- ## Method Details

  - ### addItemId

    public void addItemId(TOP srcFs, int tgtId, boolean inTarget)
    Add a new FS id - done during prescan of source during serialization Must call in heap scan order
    Parameters:
      `srcFs` - -
      `tgtId` - -
      `inTarget` - true if this type is in the target

  - ### addSrcFsForTgt

    public void addSrcFsForTgt(TOP srcFs, boolean inSrc)
    Called during deserialize to incrementally add
    Parameters:
      `srcFs` - -
      `inSrc` - -

  - ### getSrcFsFromTgtSeq

    public TOP getSrcFsFromTgtSeq(int seq)
    Parameters:
      `seq` - -
    Returns:
      0 means target seq doesn't exist in source CAS

  - ### getTgtSeqFromSrcAddr

    public int getTgtSeqFromSrcAddr(int itemAddr)
    Parameters:
      `itemAddr` - -
    Returns:
      -1 if src addr not in target seq

  - ### getNumberSrcFss

    public int getNumberSrcFss()