org.apache.ignite.internal.processors.cache

## Class PartitionUpdateCounter

- java.lang.Object
- - org.apache.ignite.internal.processors.cache.PartitionUpdateCounter

    public class PartitionUpdateCounter
    extends Object

Partition update counter with MVCC delta updates capabilities.

### Method Summary

All Methods Instance Methods Concrete Methods
`void` `finalizeUpdateCountres()` Flushes pending update counters closing all possible gaps.
`long` `get()`
`long` `getAndAdd(long delta)` Adds delta to current counter value.
`void` `init(long updateCntr)` Sets init counter.
`long` `initial()`
`long` `next()`
`void` `update(long val)` Sets value to update counter,
`void` `update(long start, long delta)` Updates counter by delta from start position.
`void` `updateInitial(long cntr)`

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

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

### Method Detail

#### init

    public void init(long updateCntr)

Sets init counter.

Parameters:
  `updateCntr` - Init counter valus.

#### initial

    public long initial()

Returns:
  Initial counter value.

#### get

    public long get()

Returns:
  Current update counter value.

#### getAndAdd

    public long getAndAdd(long delta)

Adds delta to current counter value.

Parameters:
  `delta` - Delta.
Returns:
  Value before add.

#### next

    public long next()

Returns:
  Next update counter.

#### update

    public void update(long val)

Sets value to update counter,

Parameters:
  `val` - Values.

#### update

    public void update(long start,
                       long delta)

Updates counter by delta from start position.

Parameters:
  `start` - Start.
  `delta` - Delta.

#### updateInitial

    public void updateInitial(long cntr)

Parameters:
  `cntr` - Sets initial counter.

#### finalizeUpdateCountres

    public void finalizeUpdateCountres()

Flushes pending update counters closing all possible gaps.

2018 Copyright © Apache Software Foundation

Follow @ApacheIgnite

Ignite Database and Caching Platform | : ver. 2.7.5
Release Date | : June 4 2019