public static class Map.MapListenerList<K,V> extends ListenerList<MapListener<K,V>> implements MapListener<K,V>
MapListener.Adapter<K,V>
Constructor and Description |
---|
Map.MapListenerList() |
Modifier and Type | Method and Description |
---|---|
void |
comparatorChanged(Map<K,V> map,
Comparator<K> previousComparator)
Called when a map's comparator has changed.
|
void |
mapCleared(Map<K,V> map)
Called when map data has been reset.
|
void |
valueAdded(Map<K,V> map,
K key)
Called when a key/value pair has been added to a map.
|
void |
valueRemoved(Map<K,V> map,
K key,
V value)
Called when a key/value pair has been removed from a map.
|
void |
valueUpdated(Map<K,V> map,
K key,
V previousValue)
Called when a map value has been updated.
|
public void valueAdded(Map<K,V> map, K key)
MapListener
valueAdded
in interface MapListener<K,V>
map
- The source of the map event.key
- The key that was added to the map.public void valueRemoved(Map<K,V> map, K key, V value)
MapListener
valueRemoved
in interface MapListener<K,V>
map
- The source of the map event.key
- The key that was removed.value
- The value that was removed.public void valueUpdated(Map<K,V> map, K key, V previousValue)
MapListener
valueUpdated
in interface MapListener<K,V>
map
- The source of the map event.key
- The key whose value was updated.previousValue
- The value that was previously associated with the key.public void mapCleared(Map<K,V> map)
MapListener
mapCleared
in interface MapListener<K,V>
map
- The source of the map event.public void comparatorChanged(Map<K,V> map, Comparator<K> previousComparator)
MapListener
comparatorChanged
in interface MapListener<K,V>
map
- The source of the event.previousComparator
- The previous comparator value.