Class SimpleMapListener<K,V>
- java.lang.Object
-
- com.oracle.coherence.spring.event.mapevent.SimpleMapListener<K,V>
-
- Type Parameters:
K
- the type of the cache keyV
- the type of the cache value
- All Implemented Interfaces:
com.tangosol.util.MapListener<K,V>
,java.lang.Comparable<SimpleMapListener<?,?>>
,java.util.EventListener
- Direct Known Subclasses:
AnnotatedMapListener
public class SimpleMapListener<K,V> extends java.lang.Object implements com.tangosol.util.MapListener<K,V>, java.lang.Comparable<SimpleMapListener<?,?>>
- Since:
- 3.0
- Author:
- Gunnar Hillert
- See Also:
MapListenerRegistrationBean.registerMapListeners(CacheLifecycleEvent)
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
WILD_CARD
The wild-card value for cache and service names.
-
Constructor Summary
Constructors Constructor Description SimpleMapListener(MethodMapListener<K,V> observer)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
addType(MapEventType type)
Add specified event type to a set of types this interceptor should handle.int
compareTo(SimpleMapListener<?,?> other)
void
entryDeleted(com.tangosol.util.MapEvent<K,V> event)
void
entryInserted(com.tangosol.util.MapEvent<K,V> event)
void
entryUpdated(com.tangosol.util.MapEvent<K,V> event)
com.tangosol.util.Filter<?>
getFilter()
Obtain theFilter
that should be used when registering this listener.MethodMapListener<K,V>
getObserver()
java.lang.String
getSession()
Return the name of the session that this listener is for.com.tangosol.util.MapEventTransformer
getTransformer()
Obtain theMapEventTransformer
that should be used when registering this listener.boolean
isSynchronous()
Returntrue
if this is synchronous event listener.void
setCacheName(java.lang.String cacheName)
void
setFilter(com.tangosol.util.Filter<?> filter)
void
setLiteEvent(boolean liteEvents)
void
setScopeName(java.lang.String scopeName)
void
setServiceName(java.lang.String serviceName)
void
setSession(java.lang.String session)
void
setSynchronousEvents(boolean synchronousEvents)
void
setTransformer(com.tangosol.util.MapEventTransformer<K,V,?> transformer)
java.lang.String
toString()
-
-
-
Field Detail
-
WILD_CARD
public static final java.lang.String WILD_CARD
The wild-card value for cache and service names.- See Also:
- Constant Field Values
-
-
Constructor Detail
-
SimpleMapListener
public SimpleMapListener(MethodMapListener<K,V> observer)
-
-
Method Detail
-
compareTo
public int compareTo(SimpleMapListener<?,?> other)
- Specified by:
compareTo
in interfacejava.lang.Comparable<K>
-
getSession
public java.lang.String getSession()
Return the name of the session that this listener is for.- Returns:
- the name of the session this listener is for
-
setSession
public void setSession(java.lang.String session)
-
getFilter
public com.tangosol.util.Filter<?> getFilter()
Obtain theFilter
that should be used when registering this listener.- Returns:
- the
Filter
that should be used when registering this listener
-
setFilter
public void setFilter(com.tangosol.util.Filter<?> filter)
-
getTransformer
public com.tangosol.util.MapEventTransformer getTransformer()
Obtain theMapEventTransformer
that should be used when registering this listener.- Returns:
- the
MapEventTransformer
that should be used when registering this listener
-
setTransformer
public void setTransformer(com.tangosol.util.MapEventTransformer<K,V,?> transformer)
-
setCacheName
public void setCacheName(java.lang.String cacheName)
-
setServiceName
public void setServiceName(java.lang.String serviceName)
-
setScopeName
public void setScopeName(java.lang.String scopeName)
-
setLiteEvent
public void setLiteEvent(boolean liteEvents)
-
isSynchronous
public boolean isSynchronous()
Returntrue
if this is synchronous event listener.
-
setSynchronousEvents
public void setSynchronousEvents(boolean synchronousEvents)
-
addType
protected void addType(MapEventType type)
Add specified event type to a set of types this interceptor should handle.- Parameters:
type
- the event type to add
-
getObserver
public MethodMapListener<K,V> getObserver()
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
-