FileDocCategorySizeDatePackage
MapEntry.javaAPI DocAndroid 1.5 API2387Wed May 06 22:41:04 BST 2009java.util

MapEntry

public class MapEntry extends Object implements Map$Entry, Cloneable
MapEntry is an internal class which provides an implementation of Map.Entry.

Fields Summary
K
key
V
value
Constructors Summary
MapEntry(K theKey)

        key = theKey;
    
MapEntry(K theKey, V theValue)

        key = theKey;
        value = theValue;
    
Methods Summary
public java.lang.Objectclone()

        try {
            return super.clone();
        } catch (CloneNotSupportedException e) {
            return null;
        }
    
public booleanequals(java.lang.Object object)

        if (this == object) {
            return true;
        }
        if (object instanceof Map.Entry) {
            Map.Entry<?, ?> entry = (Map.Entry<?, ?>) object;
            return (key == null ? entry.getKey() == null : key.equals(entry
                    .getKey()))
                    && (value == null ? entry.getValue() == null : value
                            .equals(entry.getValue()));
        }
        return false;
    
public KgetKey()

        return key;
    
public VgetValue()

        return value;
    
public inthashCode()

        return (key == null ? 0 : key.hashCode())
                ^ (value == null ? 0 : value.hashCode());
    
public VsetValue(V object)

        V result = value;
        value = object;
        return result;
    
public java.lang.StringtoString()

        return key + "=" + value;