org.eclipse.rdf4j.http.client

## Class QueueCursor<E>

- java.lang.Object
- - org.eclipse.rdf4j.common.iteration.AbstractCloseableIteration<E,X>
  - - org.eclipse.rdf4j.common.iteration.LookAheadIteration<E,T>
    - - org.eclipse.rdf4j.common.iteration.QueueIteration<E,QueryEvaluationException>
      - - org.eclipse.rdf4j.query.impl.QueueCursor<E>
        - - org.eclipse.rdf4j.http.client.QueueCursor<E>

- All Implemented Interfaces:
    AutoCloseable, CloseableIteration<E,QueryEvaluationException>, Iteration<E,QueryEvaluationException>
  Direct Known Subclasses:
    QueueCursor, QueueCursor

  Deprecated.
  Use `QueueCursor` instead

      @Deprecated
      public class QueueCursor<E>
      extends QueueCursor<E>

  Makes working with a queue easier by adding the methods `QueueIteration.done()` and `QueueIteration.toss(Exception)` and automatically converting the exception into a QueryEvaluationException with an appropriate stack trace.
  Author:
    James Leigh

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `QueueCursor(int capacity)` Deprecated. Creates an `QueueCursor` with the given (fixed) capacity and default access policy.
    `QueueCursor(int capacity, boolean fair)` Deprecated. Creates an `QueueCursor` with the given (fixed) capacity and the specified access policy.

  - ### Method Summary

    All Methods Instance Methods Concrete Methods Deprecated Methods
    Modifier and Type | Method and Description
    --- | ---
    `protected QueryEvaluationException` | `convert(Exception e)` Deprecated. Converts an exception from the underlying iteration to an exception of type `X`.

    - ### Methods inherited from class org.eclipse.rdf4j.common.iteration.QueueIteration

      `checkException, done, getNextElement, handleClose, put, toss`

    - ### Methods inherited from class org.eclipse.rdf4j.common.iteration.LookAheadIteration

      `hasNext, next, remove`

    - ### Methods inherited from class org.eclipse.rdf4j.common.iteration.AbstractCloseableIteration

      `close, isClosed`

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

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

    - ### Methods inherited from interface org.eclipse.rdf4j.common.iteration.Iteration

      `stream`

- - ### Constructor Detail

    - #### QueueCursor

          public QueueCursor(int capacity)

      Deprecated.
      Creates an `QueueCursor` with the given (fixed) capacity and default access policy.
      Parameters:
        `capacity` - the capacity of this queue

    - #### QueueCursor

          public QueueCursor(int capacity,
                             boolean fair)

      Deprecated.
      Creates an `QueueCursor` with the given (fixed) capacity and the specified access policy.
      Parameters:
        `capacity` - the capacity of this queue
        `fair` - if `true` then queue accesses for threads blocked on insertion or removal, are processed in FIFO order; if `false` the access order is unspecified.

  - ### Method Detail

    - #### convert

          protected QueryEvaluationException convert(Exception e)

      Deprecated.
      Description copied from class: `QueueIteration`
      Converts an exception from the underlying iteration to an exception of type `X`.
      Overrides:
        `convert` in class `QueueCursor<E>`

Copyright © 2015-2021 Eclipse Foundation. All Rights Reserved.