Class AnnotationMirrorMap<V>

java.lang.Object
org.checkerframework.framework.util.AnnotationMirrorMap<V>
All Implemented Interfaces:
Map<AnnotationMirror,V>

public class AnnotationMirrorMap<V> extends Object implements Map<AnnotationMirror,V>
The Map interface defines some of its methods with respect to the equals method. This implementation of Map violates those specifications, but fulfills the same property using AnnotationUtils.areSame(javax.lang.model.element.AnnotationMirror, javax.lang.model.element.AnnotationMirror).

For example, the specification for the containsKey(Object key) method says: "returns true if and only if this map contains a mapping for a key k such that (key == null ? k == null : key.equals(k))." The specification for containsKey(java.lang.Object) is "returns true if and only if this map contains a mapping for a key k such that (key == null ? k == null : AnnotationUtils.areSame(key, k))."

AnnotationMirror is an interface and not all implementing classes provide a correct equals method; therefore, existing implementations of Map cannot be used.