Java java.util EnumMap fields, constructors, methods, implement or subclass

Example usage for Java java.util EnumMap fields, constructors, methods, implement or subclass

Introduction

In this page you can find the methods, fields and constructors for java.util EnumMap.

The text is from its open source code.

Subclass

java.util.EnumMap has subclasses.
Click this link to see all its subclasses.

Field

intsize
The number of mappings in this map.
SetentrySet
This field is initialized to contain an instance of the entry set view the first time this view is requested.

Constructor

EnumMap(Class keyType)
Creates an empty enum map with the specified key type.
EnumMap(EnumMap m)
Creates an enum map with the same key type as the specified enum map, initially containing the same mappings (if any).
EnumMap(Map m)
Creates an enum map initialized from the specified map.

Method

voidclear()
Removes all mappings from this map.
EnumMapclone()
Returns a shallow copy of this enum map.
booleancontainsKey(Object key)
Returns true if this map contains a mapping for the specified key.
booleancontainsValue(Object value)
Returns true if this map maps one or more keys to the specified value.
booleanequals(Object o)
Compares the specified object with this map for equality.
booleanequals(EnumMap em)
Vget(Object key)
Returns the value to which the specified key is mapped, or null if this map contains no mapping for the key.
ClassgetClass()
Returns the runtime class of this Object .
inthashCode()
Returns the hash code value for this map.
SetkeySet()
Returns a Set view of the keys contained in this map.
Vput(K key, V value)
Associates the specified value with the specified key in this map.
voidputAll(Map m)
Copies all of the mappings from the specified map to this map.
Vremove(Object key)
Removes the mapping for this key from this map if present.
StringtoString()
Returns a string representation of the object.
Collectionvalues()
Returns a Collection view of the values contained in this map.