org.modeshape.common.collection.ring

## Interface DependentOnPointers

- All Known Subinterfaces:
    Cursor
  All Known Implementing Classes:
    GarbageCollectingConsumer, SingleProducerCursor, TrailingPointer

      public interface DependentOnPointers

  An interface that defines methods to add and remove dependent `Pointer`s.

- - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `boolean` | `ignore(Pointer pointer)` Ignore the specified pointer that cursor had previously `stayed behind`.
    `void` | `stayBehind(Pointer... pointers)` Ensure that this cursor always remains behind the specified pointer.

- - ### Method Detail

    - #### stayBehind

          void stayBehind(Pointer... pointers)

      Ensure that this cursor always remains behind the specified pointer.
      Parameters:
        `pointers` - the pointers that this cursor may not run past in the ring buffer

    - #### ignore

          boolean ignore(Pointer pointer)

      Ignore the specified pointer that cursor had previously `stayed behind`. This should be called when the supplied pointer is removed from the ring buffer.
      Parameters:
        `pointer` - the pointer that this cursor may no longer depend upon
      Returns:
        true if this cursor did depend on the supplied pointer and now no longer does, or false if this cursor never dependent upon the supplied pointer

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