Modifier and Type | Field and Description |
---|---|
static io.vertx.lang.rx.TypeArg<Counter> |
__TYPE_ARG |
Constructor and Description |
---|
Counter(Counter delegate) |
Counter(Object delegate) |
Modifier and Type | Method and Description |
---|---|
void |
addAndGet(long value)
Add the value to the counter atomically and return the new count
|
void |
addAndGet(long value,
Handler<AsyncResult<Long>> resultHandler)
Add the value to the counter atomically and return the new count
|
void |
compareAndSet(long expected,
long value)
Set the counter to the specified value only if the current value is the expectec value.
|
void |
compareAndSet(long expected,
long value,
Handler<AsyncResult<Boolean>> resultHandler)
Set the counter to the specified value only if the current value is the expectec value.
|
void |
decrementAndGet()
Decrement the counter atomically and return the new count
|
void |
decrementAndGet(Handler<AsyncResult<Long>> resultHandler)
Decrement the counter atomically and return the new count
|
boolean |
equals(Object o) |
void |
get()
Get the current value of the counter
|
void |
get(Handler<AsyncResult<Long>> resultHandler)
Get the current value of the counter
|
void |
getAndAdd(long value)
Add the value to the counter atomically and return the value before the add
|
void |
getAndAdd(long value,
Handler<AsyncResult<Long>> resultHandler)
Add the value to the counter atomically and return the value before the add
|
void |
getAndIncrement()
Increment the counter atomically and return the value before the increment.
|
void |
getAndIncrement(Handler<AsyncResult<Long>> resultHandler)
Increment the counter atomically and return the value before the increment.
|
Counter |
getDelegate() |
int |
hashCode() |
void |
incrementAndGet()
Increment the counter atomically and return the new count
|
void |
incrementAndGet(Handler<AsyncResult<Long>> resultHandler)
Increment the counter atomically and return the new count
|
static Counter |
newInstance(Counter arg) |
Single<Long> |
rxAddAndGet(long value)
Add the value to the counter atomically and return the new count
|
Single<Boolean> |
rxCompareAndSet(long expected,
long value)
Set the counter to the specified value only if the current value is the expectec value.
|
Single<Long> |
rxDecrementAndGet()
Decrement the counter atomically and return the new count
|
Single<Long> |
rxGet()
Get the current value of the counter
|
Single<Long> |
rxGetAndAdd(long value)
Add the value to the counter atomically and return the value before the add
|
Single<Long> |
rxGetAndIncrement()
Increment the counter atomically and return the value before the increment.
|
Single<Long> |
rxIncrementAndGet()
Increment the counter atomically and return the new count
|
String |
toString() |
public static final io.vertx.lang.rx.TypeArg<Counter> __TYPE_ARG
public Counter getDelegate()
public void get(Handler<AsyncResult<Long>> resultHandler)
resultHandler
- handler which will be passed the valuepublic void get()
public void incrementAndGet(Handler<AsyncResult<Long>> resultHandler)
resultHandler
- handler which will be passed the valuepublic void incrementAndGet()
public Single<Long> rxIncrementAndGet()
public void getAndIncrement(Handler<AsyncResult<Long>> resultHandler)
resultHandler
- handler which will be passed the valuepublic void getAndIncrement()
public Single<Long> rxGetAndIncrement()
public void decrementAndGet(Handler<AsyncResult<Long>> resultHandler)
resultHandler
- handler which will be passed the valuepublic void decrementAndGet()
public Single<Long> rxDecrementAndGet()
public void addAndGet(long value, Handler<AsyncResult<Long>> resultHandler)
value
- the value to addresultHandler
- handler which will be passed the valuepublic void addAndGet(long value)
value
- the value to addpublic Single<Long> rxAddAndGet(long value)
value
- the value to addpublic void getAndAdd(long value, Handler<AsyncResult<Long>> resultHandler)
value
- the value to addresultHandler
- handler which will be passed the valuepublic void getAndAdd(long value)
value
- the value to addpublic Single<Long> rxGetAndAdd(long value)
value
- the value to addpublic void compareAndSet(long expected, long value, Handler<AsyncResult<Boolean>> resultHandler)
expected
- the expected valuevalue
- the new valueresultHandler
- the handler will be passed true on successpublic void compareAndSet(long expected, long value)
expected
- the expected valuevalue
- the new valuepublic Single<Boolean> rxCompareAndSet(long expected, long value)
expected
- the expected valuevalue
- the new valueCopyright © 2024 Eclipse. All rights reserved.