@Test public void testAtomicLong() { AtomicNumber an = Hazelcast.getAtomicNumber("testAtomicLong"); assertEquals(0, an.get()); assertEquals(-1, an.decrementAndGet()); assertEquals(0, an.incrementAndGet()); assertEquals(1, an.incrementAndGet()); assertEquals(2, an.incrementAndGet()); assertEquals(1, an.decrementAndGet()); assertEquals(1, an.getAndSet(23)); assertEquals(28, an.addAndGet(5)); assertEquals(28, an.get()); assertEquals(28, an.getAndAdd(-3)); assertEquals(24, an.decrementAndGet()); Assert.assertFalse(an.compareAndSet(23, 50)); assertTrue(an.compareAndSet(24, 50)); assertTrue(an.compareAndSet(50, 0)); }
@Deprecated public static AtomicNumber getAtomicNumber(String name) { return getDefaultInstance().getAtomicNumber(name); }
Hazelcast { @Deprecated public static AtomicNumber getAtomicNumber(String name) { return getDefaultInstance().getAtomicNumber(name); } }
Hazelcast { @Deprecated public static AtomicNumber getAtomicNumber(String name) { return getDefaultInstance().getAtomicNumber(name); } private  Hazelcast(); }
Hazelcast { @Deprecated public static AtomicNumber getAtomicNumber(String name) { return getDefaultInstance().getAtomicNumber(name); } private  Hazelcast(); @Deprecated static HazelcastInstance init(Config config); @Deprecated static HazelcastInstance getDefaultInstance(); @Deprecated static IQueue<E> getQueue(String name); @Deprecated static ITopic<E> getTopic(String name); @Deprecated static ISet<E> getSet(String name); @Deprecated static IList<E> getList(String name); @Deprecated static IMap<K, V> getMap(String name); @Deprecated static MultiMap<K, V> getMultiMap(String name); @Deprecated static ILock getLock(Object key); @Deprecated static Cluster getCluster(); @Deprecated static ExecutorService getExecutorService(); @Deprecated static ExecutorService getExecutorService(String name); @Deprecated static Transaction getTransaction(); @Deprecated static AtomicNumber getAtomicNumber(String name); @Deprecated static ICountDownLatch getCountDownLatch(String name); @Deprecated static ISemaphore getSemaphore(String name); @Deprecated static IdGenerator getIdGenerator(String name); @Deprecated static void shutdown(); static void shutdownAll(); @Deprecated static void restart(); @Deprecated static Collection<Instance> getInstances(); @Deprecated static void addInstanceListener(InstanceListener instanceListener); @Deprecated static void removeInstanceListener(InstanceListener instanceListener); static HazelcastInstance newHazelcastInstance(Config config); static HazelcastInstance newHazelcastInstance(); static HazelcastInstance newLiteMemberHazelcastInstance(); static HazelcastInstance getHazelcastInstanceByName(String instanceName); static Set<HazelcastInstance> getAllHazelcastInstances(); @Deprecated static Config getConfig(); @Deprecated static PartitionService getPartitionService(); @Deprecated static LoggingService getLoggingService(); @Deprecated static LifecycleService getLifecycleService(); static void setOutOfMemoryHandler(OutOfMemoryHandler outOfMemoryHandler); }
Hazelcast { @Deprecated public static AtomicNumber getAtomicNumber(String name) { return getDefaultInstance().getAtomicNumber(name); } private  Hazelcast(); @Deprecated static HazelcastInstance init(Config config); @Deprecated static HazelcastInstance getDefaultInstance(); @Deprecated static IQueue<E> getQueue(String name); @Deprecated static ITopic<E> getTopic(String name); @Deprecated static ISet<E> getSet(String name); @Deprecated static IList<E> getList(String name); @Deprecated static IMap<K, V> getMap(String name); @Deprecated static MultiMap<K, V> getMultiMap(String name); @Deprecated static ILock getLock(Object key); @Deprecated static Cluster getCluster(); @Deprecated static ExecutorService getExecutorService(); @Deprecated static ExecutorService getExecutorService(String name); @Deprecated static Transaction getTransaction(); @Deprecated static AtomicNumber getAtomicNumber(String name); @Deprecated static ICountDownLatch getCountDownLatch(String name); @Deprecated static ISemaphore getSemaphore(String name); @Deprecated static IdGenerator getIdGenerator(String name); @Deprecated static void shutdown(); static void shutdownAll(); @Deprecated static void restart(); @Deprecated static Collection<Instance> getInstances(); @Deprecated static void addInstanceListener(InstanceListener instanceListener); @Deprecated static void removeInstanceListener(InstanceListener instanceListener); static HazelcastInstance newHazelcastInstance(Config config); static HazelcastInstance newHazelcastInstance(); static HazelcastInstance newLiteMemberHazelcastInstance(); static HazelcastInstance getHazelcastInstanceByName(String instanceName); static Set<HazelcastInstance> getAllHazelcastInstances(); @Deprecated static Config getConfig(); @Deprecated static PartitionService getPartitionService(); @Deprecated static LoggingService getLoggingService(); @Deprecated static LifecycleService getLifecycleService(); static void setOutOfMemoryHandler(OutOfMemoryHandler outOfMemoryHandler);  }