Class EnterpriseHazelcastCounter

java.lang.Object
com.hazelcast.vertx.io.vertx.spi.cluster.hazelcast.impl.EnterpriseHazelcastCounter
All Implemented Interfaces:
io.vertx.core.shareddata.Counter

public class EnterpriseHazelcastCounter extends Object implements io.vertx.core.shareddata.Counter
Implementation of Counter based on Hazelcast CP Subsystem
  • Constructor Details

    • EnterpriseHazelcastCounter

      public EnterpriseHazelcastCounter(io.vertx.core.internal.VertxInternal vertx, com.hazelcast.cp.IAtomicLong atomicLong)
  • Method Details

    • get

      public io.vertx.core.Future<Long> get()
      Specified by:
      get in interface io.vertx.core.shareddata.Counter
    • incrementAndGet

      public io.vertx.core.Future<Long> incrementAndGet()
      Specified by:
      incrementAndGet in interface io.vertx.core.shareddata.Counter
    • getAndIncrement

      public io.vertx.core.Future<Long> getAndIncrement()
      Specified by:
      getAndIncrement in interface io.vertx.core.shareddata.Counter
    • decrementAndGet

      public io.vertx.core.Future<Long> decrementAndGet()
      Specified by:
      decrementAndGet in interface io.vertx.core.shareddata.Counter
    • addAndGet

      public io.vertx.core.Future<Long> addAndGet(long value)
      Specified by:
      addAndGet in interface io.vertx.core.shareddata.Counter
    • getAndAdd

      public io.vertx.core.Future<Long> getAndAdd(long value)
      Specified by:
      getAndAdd in interface io.vertx.core.shareddata.Counter
    • compareAndSet

      public io.vertx.core.Future<Boolean> compareAndSet(long expected, long value)
      Specified by:
      compareAndSet in interface io.vertx.core.shareddata.Counter