Package org.assertj.core.data
Class MapEntry<K,V>
- java.lang.Object
-
- org.assertj.core.data.MapEntry<K,V>
-
- Type Parameters:
K
- the type of the key of this entry.V
- the type of the value of this entry.
- All Implemented Interfaces:
java.util.Map.Entry<K,V>
public class MapEntry<K,V> extends java.lang.Object implements java.util.Map.Entry<K,V>
Understands an entry in a
.Map
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static <K,V>
MapEntry<K,V>entry(K key, V value)
Creates a newMapEntry
.boolean
equals(java.lang.Object object)
K
getKey()
V
getValue()
int
hashCode()
V
setValue(V value)
Always throwsUnsupportedOperationException
as this class represents an immutable map entry.java.lang.String
toString()
-
-
-
Method Detail
-
entry
public static <K,V> MapEntry<K,V> entry(K key, V value)
Creates a newMapEntry
.- Type Parameters:
K
- the type of the key of this entry.V
- the type of the value of this entry.- Parameters:
key
- the key of the entry to create.value
- the value of the entry to create.- Returns:
- the created
MapEntry
.
-
equals
public boolean equals(java.lang.Object object)
-
hashCode
public int hashCode()
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
-