Package it.tidalwave.util
Class TypeSafeHashMap
- java.lang.Object
-
- it.tidalwave.util.TypeSafeHashMap
-
- All Implemented Interfaces:
TypeSafeMap,Serializable,Iterable<Object>
@Immutable public class TypeSafeHashMap extends Object implements TypeSafeMap, Serializable
- Version:
- $Id$
- Author:
- Fabrizio Giudici
- See Also:
- Serialized Form
- Status: draft API
-
-
Constructor Summary
Constructors Constructor Description TypeSafeHashMap(Map<Key<?>,Object> map)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Map<Key<?>,Object>asMap()booleancontainsKey(Key<?> key)<T> Tget(Key<T> key)Set<Key<?>>getKeys()intgetSize()Iterator<Object>iterator()StringtoString()-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface java.lang.Iterable
forEach, spliterator
-
-
-
-
Method Detail
-
get
@Nonnull public <T> T get(@Nonnull Key<T> key) throws NotFoundException
- Specified by:
getin interfaceTypeSafeMap- Throws:
NotFoundException
-
containsKey
public boolean containsKey(@Nonnull Key<?> key)
- Specified by:
containsKeyin interfaceTypeSafeMap
-
getKeys
@Nonnull public Set<Key<?>> getKeys()
- Specified by:
getKeysin interfaceTypeSafeMap
-
getSize
@Nonnegative public int getSize()
- Specified by:
getSizein interfaceTypeSafeMap
-
-