## Uses of Class
org.apache.cassandra.utils.CounterId

- Packages that use CounterId
  Package | Description
  --- | ---
  org.apache.cassandra.db.context |
  org.apache.cassandra.utils |

- - ### Uses of CounterId in org.apache.cassandra.db.context

    Methods in org.apache.cassandra.db.context that return CounterId
    Modifier and Type | Method and Description
    --- | ---
    `CounterId` | CounterContext.ContextState.`getCounterId()`

    Methods in org.apache.cassandra.db.context with parameters of type CounterId
    Modifier and Type | Method and Description
    --- | ---
    `java.nio.ByteBuffer` | CounterContext.`createGlobal(CounterId id, long clock, long count)` Creates a counter context with a single global, 2.1+ shard (a result of increment).
    `java.nio.ByteBuffer` | CounterContext.`createRemote(CounterId id, long clock, long count)` Creates a counter context with a single remote shard.
    `int` | CounterContext.`findPositionOf(java.nio.ByteBuffer context, CounterId id)` Finds the position of a shard with the given id within the context (via binary search).
    `ClockAndCount` | CounterContext.`getClockAndCountOf(java.nio.ByteBuffer context, CounterId id)` Returns the clock and the count associated with the given counter id, or (0, 0) if no such shard is present.
    `void` | CounterContext.ContextState.`writeGlobal(CounterId id, long clock, long count)`
    `void` | CounterContext.ContextState.`writeLocal(CounterId id, long clock, long count)`
    `void` | CounterContext.ContextState.`writeRemote(CounterId id, long clock, long count)`

  - ### Uses of CounterId in org.apache.cassandra.utils

    Methods in org.apache.cassandra.utils that return CounterId
    Modifier and Type | Method and Description
    --- | ---
    `static CounterId` | CounterId.`fromInt(int n)` Pack an int in a valid CounterId so that the resulting ids respects the numerical ordering.
    `static CounterId` | CounterId.`generate()`
    `static CounterId` | CounterId.`getLocalId()`
    `static CounterId` | CounterId.`wrap(java.nio.ByteBuffer id)`
    `static CounterId` | CounterId.`wrap(java.nio.ByteBuffer bb, int offset)`

    Methods in org.apache.cassandra.utils with parameters of type CounterId
    Modifier and Type | Method and Description
    --- | ---
    `int` | CounterId.`compareTo(CounterId o)`

Copyright © 2018 The Apache Software Foundation