Class SimpleMapEvent<K,V>
- java.lang.Object
-
- com.tangosol.coherence.rest.events.SimpleMapEvent<K,V>
-
-
Constructor Summary
Constructors Constructor Description SimpleMapEvent()
Deserialization constructor.SimpleMapEvent(MapEvent<? extends K,? extends V> evt)
Construct SimpleMapEvent instance.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String
getCache()
Return the cache name.K
getKey()
Return the key associated with this event.V
getNewValue()
Return the new value associated with this event.V
getOldValue()
Return the old value associated with this event.int
getType()
Return the event type.void
setCache(String sCache)
Set the cache name.void
setKey(K key)
Set the key for this event.void
setNewValue(V newValue)
Set the new value.void
setOldValue(V oldValue)
Set the old value.void
setType(int nType)
Set the event type.String
toString()
-
-
-
Method Detail
-
getCache
public String getCache()
Return the cache name.- Returns:
- the cache name
-
setCache
public void setCache(String sCache)
Set the cache name.- Parameters:
sCache
- the cache name
-
getType
public int getType()
Return the event type.The value is one of:
- INSERTED
- UPDATED
- DELETED
Unlike SSE event name, which is calculated for update operations when filter-based listeners are used, this attribute always represents the actual operation that occured on the underlying cache.
- Returns:
- the event type
-
setType
public void setType(int nType)
Set the event type.- Parameters:
nType
- the event type
-
getKey
public K getKey()
Return the key associated with this event.- Returns:
- the key
-
setKey
public void setKey(K key)
Set the key for this event.- Parameters:
key
- the key
-
getOldValue
public V getOldValue()
Return the old value associated with this event.The old value represents a value deleted from or updated in a map. It is always null for "insert" notifications.
- Returns:
- the old value
-
setOldValue
public void setOldValue(V oldValue)
Set the old value.- Parameters:
oldValue
- the old value
-
getNewValue
public V getNewValue()
Return the new value associated with this event.The new value represents a new value inserted into or updated in a map. It is always null for "delete" notifications.
- Returns:
- the new value
-
setNewValue
public void setNewValue(V newValue)
Set the new value.- Parameters:
newValue
- the new value
-
-