Package io.grpc.internal
Class AtomicLongCounter
java.lang.Object
io.grpc.internal.AtomicLongCounter
- All Implemented Interfaces:
LongCounter
An implementation of
LongCounter that is just an AtomicLong.-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
-
Field Details
-
counter
-
-
Constructor Details
-
AtomicLongCounter
AtomicLongCounter()Creates anAtomicLongCounter.
-
-
Method Details
-
add
public void add(long delta) Description copied from interface:LongCounterAdds the delta to this counter.- Specified by:
addin interfaceLongCounter
-
value
public long value()Description copied from interface:LongCounterReturns the value of this counter.- Specified by:
valuein interfaceLongCounter
-