Class AlignmentTools.IdentityMap<K>
- java.lang.Object
-
- java.util.AbstractMap<K,K>
-
- org.biojava.nbio.structure.align.util.AlignmentTools.IdentityMap<K>
-
- Type Parameters:
K
-
- All Implemented Interfaces:
java.util.Map<K,K>
- Enclosing class:
- AlignmentTools
public static class AlignmentTools.IdentityMap<K> extends java.util.AbstractMap<K,K>
A Mapcan be viewed as a function from K to V. This class represents the identity function. Getting a value results in the value itself. The class is a bit inconsistent when representing its contents. On the one hand, containsKey(key) is true for all objects. However, attempting to iterate through the values returns an empty set.
- Author:
- Spencer Bliven
-
-
Constructor Summary
Constructors Constructor Description IdentityMap()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
containsKey(java.lang.Object key)
java.util.Set<java.util.Map.Entry<K,K>>
entrySet()
Always returns the empty setK
get(java.lang.Object key)
-
Methods inherited from class java.util.AbstractMap
clear, clone, containsValue, equals, hashCode, isEmpty, keySet, put, putAll, remove, size, toString, values
-
-