Package io.atomix.client.map
Class MultimapEvent<K,V>
- Type Parameters:
K- key typeV- value type
- All Implemented Interfaces:
Event<MultimapEvent.Type,K>
Representation of a ConsistentMultimap update notification.
-
Nested Class Summary
Nested Classes -
Constructor Summary
ConstructorsConstructorDescriptionMultimapEvent(MultimapEvent.Type type, K key, V newValue, V oldValue) Creates a new event object. -
Method Summary
Methods inherited from class io.atomix.client.event.AbstractEvent
subject, time, type
-
Constructor Details
-
MultimapEvent
Creates a new event object.- Parameters:
type- the event typekey- key the event concernsnewValue- new value key is mapped tooldValue- previous value that was mapped to the key
-
-
Method Details
-
key
Returns the key.- Returns:
- the key
-
newValue
Returns the new value in the map associated with the key. IfAbstractEvent.type()returnsREMOVE, this method will returnnull.- Returns:
- the new value for key
-
oldValue
Returns the old value that was associated with the key. IfAbstractEvent.type()returnsINSERT, this method will returnnull.- Returns:
- the old value that was mapped to the key
-
equals
-
hashCode
public int hashCode() -
toString
- Overrides:
toStringin classAbstractEvent<MultimapEvent.Type,K>
-