Module datarush.library
Package com.pervasive.datarush.tokens
Class DefaultModificationCountProvider
- java.lang.Object
-
- com.pervasive.datarush.tokens.DefaultModificationCountProvider
-
- All Implemented Interfaces:
ModificationCountProvider
public class DefaultModificationCountProvider extends Object implements ModificationCountProvider
Provides a change number sequence which is manually managed. The creator is responsible for advancing the sequence.
-
-
Constructor Summary
Constructors Constructor Description DefaultModificationCountProvider()
Creates a new change number sequence.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description long
getModificationCount()
Gets the current change number.void
increment()
Increment the current change number.
-
-
-
Method Detail
-
getModificationCount
public long getModificationCount()
Description copied from interface:ModificationCountProvider
Gets the current change number. This value is monotonically increasing; a change in value indicates a change to the data structure associated with the provider.- Specified by:
getModificationCount
in interfaceModificationCountProvider
- Returns:
- the current sequence number
-
increment
public void increment()
Increment the current change number. Subsequent calls togetModificationCount()
will see the new counter value.
-
-