org.apache.clerezza.triaxrs.util
Interface SimpleMap<K,V>

All Known Implementing Classes:
SoftConcurrentMap

public interface SimpleMap<K,V>

Simplified definition of the Map with only three operations: get, put and clear.

Pay attention that the method may behave slightly differently from the methods define by the Map interface, therefore it's recommended you always check the javadoc of the implementing class.


Method Summary
 void clear()
          Removes all mappings from this map (optional operation).
 V get(K key)
          Returns the value to which this map maps the specified key.
 V put(K key, V value)
          Associates the specified value with the specified key in this map.
 

Method Detail

get

V get(K key)
Returns the value to which this map maps the specified key. Returns null if the map contains no mapping for this key. A return value of null does not necessarily indicate that the map contains no mapping for the key; it's also possible that the map explicitly maps the key to null.


put

V put(K key,
      V value)
Associates the specified value with the specified key in this map. If the map previously contained a mapping for this key, the old value is replaced by the specified value.


clear

void clear()
Removes all mappings from this map (optional operation).



Copyright © 2012 The Apache Software Foundation. All Rights Reserved.