producerIndex >= consumerIndex
As an invariant, but in a concurrent, long running settings all of the following need to be considered:
consumerIndex > producerIndex : due to counter overflow (unlikey with longs, but easy to reason)
consumerIndex > producerIndex : due to consumer FastFlow like implementation discovering the
element before the counter is updated.
producerIndex - consumerIndex < 0 : due to above.
producerIndex - consumerIndex > Integer.MAX_VALUE : as linked buffers allow constructing queues
with more than Integer.MAX_VALUE elements.
| Modifier and Type | Class and Description |
|---|---|
| public static interface |
| Modifier and Type | Field and Description |
|---|---|
| public static final int | |
| public static final int |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public static boolean | |
| public static int | |
| public static int |
| IGNORE_PARITY_DIVISOR | back to summary |
|---|---|
| public static final int IGNORE_PARITY_DIVISOR | |
| PLAIN_DIVISOR | back to summary |
|---|---|
| public static final int PLAIN_DIVISOR | |
| IndexedQueueSizeUtil | back to summary |
|---|---|
| public IndexedQueueSizeUtil() | |
| isEmpty | back to summary |
|---|---|
| public static boolean isEmpty(IndexedQueueSizeUtil. | |
| sanitizedSize | back to summary |
|---|---|
| public static int sanitizedSize(int capacity, long size) | |
| size | back to summary |
|---|---|
| public static int size(IndexedQueueSizeUtil. | |
| Modifier and Type | Method and Description |
|---|---|
| public int | |
| public long | |
| public long |
| capacity | back to summary |
|---|---|
| public int capacity() | |
| lvConsumerIndex | back to summary |
|---|---|
| public long lvConsumerIndex() | |
| lvProducerIndex | back to summary |
|---|---|
| public long lvProducerIndex() | |