public class SequenceNumberManager
extends java.lang.Object
Constructor and Description |
---|
SequenceNumberManager() |
Modifier and Type | Method and Description |
---|---|
long |
get() |
long |
getAndIncrement() |
void |
update(long otherSequenceNumber)
updates the sequence number to the maximum between them
|
long |
updateAndGet(long otherSequenceNumber)
updates the sequence number and returns the next, that will be used a propose sequence number
|
public long getAndIncrement()
public void update(long otherSequenceNumber)
otherSequenceNumber
- the sequence number receivedpublic long updateAndGet(long otherSequenceNumber)
otherSequenceNumber
- the sequence number receivedpublic long get()
Copyright © 1998-2020 Red Hat. All Rights Reserved.