Search in sources :

Example 16 with EntryListener

use of com.hazelcast.core.EntryListener in project hazelcast by hazelcast.

the class MapPreconditionsTest method testAddLocalEntryListenerWithEntryListenerAndPredicateAndKey_NullPredicate.

@Test(expected = NullPointerException.class)
public void testAddLocalEntryListenerWithEntryListenerAndPredicateAndKey_NullPredicate() {
    EntryListener entryListener = new TestEntryListener();
    Predicate predicate = null;
    map.addLocalEntryListener(entryListener, predicate, null, true);
}
Also used : EntryListener(com.hazelcast.core.EntryListener) TruePredicate(com.hazelcast.query.TruePredicate) Predicate(com.hazelcast.query.Predicate) QuickTest(com.hazelcast.test.annotation.QuickTest) Test(org.junit.Test) ParallelTest(com.hazelcast.test.annotation.ParallelTest)

Example 17 with EntryListener

use of com.hazelcast.core.EntryListener in project hazelcast by hazelcast.

the class MapPreconditionsTest method testAddEntryListenerWithEntryListenerAndPredicate_NullPredicate.

@Test(expected = NullPointerException.class)
public void testAddEntryListenerWithEntryListenerAndPredicate_NullPredicate() {
    EntryListener entryListener = new TestEntryListener();
    Predicate predicate = null;
    map.addEntryListener(entryListener, predicate, true);
}
Also used : EntryListener(com.hazelcast.core.EntryListener) TruePredicate(com.hazelcast.query.TruePredicate) Predicate(com.hazelcast.query.Predicate) QuickTest(com.hazelcast.test.annotation.QuickTest) Test(org.junit.Test) ParallelTest(com.hazelcast.test.annotation.ParallelTest)

Example 18 with EntryListener

use of com.hazelcast.core.EntryListener in project hazelcast by hazelcast.

the class MapPreconditionsTest method testAddLocalEntryListenerWithEntryListener.

@Test(expected = NullPointerException.class)
public void testAddLocalEntryListenerWithEntryListener() {
    EntryListener entryListener = null;
    map.addLocalEntryListener(entryListener);
}
Also used : EntryListener(com.hazelcast.core.EntryListener) QuickTest(com.hazelcast.test.annotation.QuickTest) Test(org.junit.Test) ParallelTest(com.hazelcast.test.annotation.ParallelTest)

Example 19 with EntryListener

use of com.hazelcast.core.EntryListener in project hazelcast by hazelcast.

the class MapPreconditionsTest method testAddEntryListenerWithEntryListener.

@Test(expected = NullPointerException.class)
public void testAddEntryListenerWithEntryListener() {
    EntryListener entryListener = null;
    map.addEntryListener(entryListener, false);
}
Also used : EntryListener(com.hazelcast.core.EntryListener) QuickTest(com.hazelcast.test.annotation.QuickTest) Test(org.junit.Test) ParallelTest(com.hazelcast.test.annotation.ParallelTest)

Example 20 with EntryListener

use of com.hazelcast.core.EntryListener in project hazelcast by hazelcast.

the class MapPreconditionsTest method testAddLocalEntryListenerWithEntryListenerAndPredicate_NullPredicate.

@Test(expected = NullPointerException.class)
public void testAddLocalEntryListenerWithEntryListenerAndPredicate_NullPredicate() {
    EntryListener entryListener = new TestEntryListener();
    Predicate predicate = null;
    map.addLocalEntryListener(entryListener, predicate, true);
}
Also used : EntryListener(com.hazelcast.core.EntryListener) TruePredicate(com.hazelcast.query.TruePredicate) Predicate(com.hazelcast.query.Predicate) QuickTest(com.hazelcast.test.annotation.QuickTest) Test(org.junit.Test) ParallelTest(com.hazelcast.test.annotation.ParallelTest)

Aggregations

EntryListener (com.hazelcast.core.EntryListener)30 ParallelTest (com.hazelcast.test.annotation.ParallelTest)26 QuickTest (com.hazelcast.test.annotation.QuickTest)26 Test (org.junit.Test)26 Predicate (com.hazelcast.query.Predicate)16 TruePredicate (com.hazelcast.query.TruePredicate)16 EntryEvent (com.hazelcast.core.EntryEvent)4 CountDownLatch (java.util.concurrent.CountDownLatch)3 EntryAdapter (com.hazelcast.core.EntryAdapter)2 SqlPredicate (com.hazelcast.query.SqlPredicate)2 HashMap (java.util.HashMap)2 Map (java.util.Map)2 AtomicInteger (java.util.concurrent.atomic.AtomicInteger)2 EntryListenerConfig (com.hazelcast.config.EntryListenerConfig)1 ReplicatedMapConfig (com.hazelcast.config.ReplicatedMapConfig)1 EntryEventType (com.hazelcast.core.EntryEventType)1 HazelcastException (com.hazelcast.core.HazelcastException)1 HazelcastInstanceAware (com.hazelcast.core.HazelcastInstanceAware)1 IMap (com.hazelcast.core.IMap)1 MapEvent (com.hazelcast.core.MapEvent)1