⇒ Index (Frames) |  ⇒ Index (No Frames) |  ⇒ Package |  ⇒ Package Tree |  ⇒ Full Tree 
org.apache.commons.collections.map

Class UnmodifiableMap

java.lang.Object
|
+--org.apache.commons.collections.map.AbstractMapDecorator
   |
   +--org.apache.commons.collections.map.UnmodifiableMap

All Implemented Interfaces:
Map, IterableMap, Unmodifiable


public final class UnmodifiableMap
extends AbstractMapDecorator
implements IterableMap, Unmodifiable

Decorates another Map to ensure it can't be altered.
Since:
Commons Collections 3.0
Author:
Stephen Colebourne

Method Summary

void

clear()

static Map

decorate(Map map)

Factory method to create an unmodifiable map.

Set

entrySet()

Set

keySet()

MapIterator

mapIterator()

Object

put(Object key, Object value)

void

putAll(Map mapToCopy)

Object

remove(Object key)

Collection

values()

Method Details

clear

public void clear()


decorate

public static Map decorate(Map map)

Factory method to create an unmodifiable map.

Parameters:
map - the map to decorate, must not be null
Throws:
- if map is null

entrySet

public Set entrySet()


keySet

public Set keySet()


mapIterator

public MapIterator mapIterator()


put

public Object put(Object key, Object value)

Parameters:
key
value

putAll

public void putAll(Map mapToCopy)

Parameters:
mapToCopy

remove

public Object remove(Object key)

Parameters:
key

values

public Collection values()