org.modeshape.jcr.query.engine.process

## Class AbstractNodeKeysSequence

- java.lang.Object
- - org.modeshape.jcr.query.NodeSequence
  - - org.modeshape.jcr.query.engine.process.DelegatingSequence
    - - org.modeshape.jcr.query.engine.process.BufferingSequence
      - - org.modeshape.jcr.query.engine.process.AbstractNodeKeysSequence

- Direct Known Subclasses:
    ExceptSequence, IntersectSequence

      @NotThreadSafe
      public abstract class AbstractNodeKeysSequence
      extends BufferingSequence

  The base class of a `NodeSequence` implementation which extracts node keys from 2 different sequences and delegates to subclasses the behavior of deciding which batches to return based on which node keys are present/absent.

- - ### Nested Class Summary

    - ### Nested classes/interfaces inherited from class org.modeshape.jcr.query.NodeSequence

      `NodeSequence.AlternateSizeBatch, NodeSequence.Batch, NodeSequence.LimitBatch, NodeSequence.MultiWidthBatch, NodeSequence.Restartable, NodeSequence.RowAccessor, NodeSequence.RowFilter, NodeSequence.SingleWidthBatch`

  - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `protected NodeSequence` | `leftSequence`
    `protected int` | `totalWidth`

    - ### Fields inherited from class org.modeshape.jcr.query.engine.process.BufferingSequence

      `buffer, cache, extractor, logger, remainingRowCount, rowFactory, trace, width, workspaceName`

    - ### Fields inherited from class org.modeshape.jcr.query.engine.process.DelegatingSequence

      `delegate`

    - ### Fields inherited from class org.modeshape.jcr.query.NodeSequence

      `LOGGER, NO_PASS_ROW_FILTER, PASS_ROW_FILTER`

  - ### Constructor Summary

    Constructors
    Modifier | Constructor and Description
    --- | ---
    `protected` | `AbstractNodeKeysSequence(String workspaceName, NodeSequence leftSequence, NodeSequence rightSequence, TypeSystem types, BufferManager bufferMgr, CachedNodeSupplier nodeCache, boolean pack, boolean useHeap)`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `protected abstract NodeSequence.Batch` | `batchWrapper(NodeSequence.Batch leftBatch)`
    `protected Object` | `keyInLeftRow(NodeSequence.Batch leftBatch)`
    `protected Iterator<BufferedRows.BufferedRow>` | `matchingRightRows(Object keyInLeft)`
    `NodeSequence.Batch` | `nextBatch()` Get the next batch of `NodeKey` instances.
    `int` | `width()` Get the number of nodes in each row.

    - ### Methods inherited from class org.modeshape.jcr.query.engine.process.BufferingSequence

      `batchFrom, close, createRow, isEmpty, loadAll, rowCount`

    - ### Methods inherited from class org.modeshape.jcr.query.engine.process.DelegatingSequence

      `getRowCount`

    - ### Methods inherited from class org.modeshape.jcr.query.NodeSequence

      `append, batchFilteredWith, batchOf, batchOf, batchOf, batchOfKeys, batchOfKeys, batchOfKeys, batchOfKeys, batchWithCount, copy, emptyBatch, emptySequence, filter, keyFor, limit, limit, merging, requireBoth, requireEither, skip, slice, slicingBatch, withBatch, withBatches, withBatches, withNode, withNodeKeys, withNodeKeys, withNodeKeys, withNodeKeys, withNodes, withNodes`

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

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

- - ### Field Detail

    - #### leftSequence

          protected final NodeSequence leftSequence

    - #### totalWidth

          protected final int totalWidth

  - ### Constructor Detail

    - #### AbstractNodeKeysSequence

          protected AbstractNodeKeysSequence(String workspaceName,
                                  NodeSequence leftSequence,
                                  NodeSequence rightSequence,
                                  TypeSystem types,
                                  BufferManager bufferMgr,
                                  CachedNodeSupplier nodeCache,
                                  boolean pack,
                                  boolean useHeap)

  - ### Method Detail

    - #### nextBatch

          public NodeSequence.Batch nextBatch()

      Description copied from class: `NodeSequence`
      Get the next batch of `NodeKey` instances.
      Overrides:
        `nextBatch` in class `DelegatingSequence`
      Returns:
        the next batch, or null if there are no more batches.

    - #### width

          public int width()

      Description copied from class: `NodeSequence`
      Get the number of nodes in each row.
      Overrides:
        `width` in class `DelegatingSequence`
      Returns:
        the width of each row; always positive

    - #### keyInLeftRow

          protected Object keyInLeftRow(NodeSequence.Batch leftBatch)

    - #### matchingRightRows

          protected Iterator<BufferedRows.BufferedRow> matchingRightRows(Object keyInLeft)

    - #### batchWrapper

          protected abstract NodeSequence.Batch batchWrapper(NodeSequence.Batch leftBatch)

Copyright © 2008-2014 JBoss, a division of Red Hat. All Rights Reserved.