public final class ReflectionLongAdderCounter extends Object implements LongCounter
LongCounter
that is implemented with a JDK8 LongAdder
. Instantiates the object
and invokes methods reflectively to avoid a compile time dependency on LongAdder.Modifier and Type | Method and Description |
---|---|
void |
add(long delta)
Adds the delta to this counter.
|
long |
value()
Returns the value of this counter.
|
public void add(long delta)
LongCounter
add
in interface LongCounter
public long value()
LongCounter
value
in interface LongCounter
Copyright © 2018. All rights reserved.