Class AbstractUnmodMap<K,​V>

    • Constructor Detail

      • AbstractUnmodMap

        public AbstractUnmodMap()
    • Method Detail

      • equals

        public boolean equals​(Object other)
        When comparing against a SortedMap, this is correct and O(n) fast, but BEWARE! It is also Compatible with AbstractMap.equals(Object) which unfortunately means equality as defined by this method (and java.util.AbstractMap) is not commutative when comparing ordered and unordered maps (it is also O(n log n) slow). The Equator defined by this class prevents comparison with unordered Maps.
        Specified by:
        equals in interface Map<K,​V>
        Overrides:
        equals in class Object