Package edu.uci.ics.jung.algorithms.util
Class BasicMapEntry<K,V>
java.lang.Object
edu.uci.ics.jung.algorithms.util.BasicMapEntry<K,V>
- Type Parameters:
K
- the key typeV
- the value type
- All Implemented Interfaces:
Map.Entry<K,
V>
An simple minimal implementation of
Map.Entry
.-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionboolean
getKey()
getValue()
int
hashCode()
(package private) void
recordAccess
(HashMap<K, V> m) This method is invoked whenever the value in an entry is overwritten by an invocation of put(k,v) for a key k that's already in the HashMap.(package private) void
recordRemoval
(HashMap<K, V> m) This method is invoked whenever the entry is removed from the table.toString()
-
Field Details
-
key
-
value
V value
-
-
Constructor Details
-
BasicMapEntry
- Parameters:
k
- the keyv
- the value
-
-
Method Details
-
getKey
-
getValue
-
setValue
-
equals
-
hashCode
public int hashCode() -
toString
-
recordAccess
This method is invoked whenever the value in an entry is overwritten by an invocation of put(k,v) for a key k that's already in the HashMap. -
recordRemoval
This method is invoked whenever the entry is removed from the table.
-