Class AbstractMapEntry

  • All Implemented Interfaces:
    java.util.Map.Entry, KeyValue
    Direct Known Subclasses:
    DefaultMapEntry, UnmodifiableMapEntry

    @Deprecated(since="2021-04-30")
    public abstract class AbstractMapEntry
    extends AbstractKeyValue
    implements java.util.Map.Entry
    Deprecated.
    Apache Commons Collections version 3.x is being deprecated from AEMaaCS. The upgraded version 4.4 of Commons Collections is already included as replacement. Customers are advised to upgrade to this version of the library. Please note: the package name was changed to org.apache.commons.collections4. Further note that there are AEM APIs currently exposing the old collections classes; these will be updated in upcoming releases.
    Abstract Pair class to assist with creating correct Map.Entry implementations.
    Since:
    Commons Collections 3.0
    • Method Summary

      All Methods Instance Methods Concrete Methods Deprecated Methods 
      Modifier and Type Method Description
      boolean equals​(java.lang.Object obj)
      Deprecated.
      Compares this Map.Entry with another Map.Entry.
      int hashCode()
      Deprecated.
      Gets a hashCode compatible with the equals method.
      java.lang.Object setValue​(java.lang.Object value)
      Deprecated.
      Sets the value stored in this Map.Entry.
      • Methods inherited from class java.lang.Object

        getClass, notify, notifyAll, wait, wait, wait
      • Methods inherited from interface java.util.Map.Entry

        getKey, getValue
    • Method Detail

      • setValue

        public java.lang.Object setValue​(java.lang.Object value)
        Deprecated.
        Sets the value stored in this Map.Entry.

        This Map.Entry is not connected to a Map, so only the local data is changed.

        Specified by:
        setValue in interface java.util.Map.Entry
        Parameters:
        value - the new value
        Returns:
        the previous value
      • equals

        public boolean equals​(java.lang.Object obj)
        Deprecated.
        Compares this Map.Entry with another Map.Entry.

        Implemented per API documentation of Map.Entry.equals(Object)

        Specified by:
        equals in interface java.util.Map.Entry
        Overrides:
        equals in class java.lang.Object
        Parameters:
        obj - the object to compare to
        Returns:
        true if equal key and value
      • hashCode

        public int hashCode()
        Deprecated.
        Gets a hashCode compatible with the equals method.

        Implemented per API documentation of Map.Entry.hashCode()

        Specified by:
        hashCode in interface java.util.Map.Entry
        Overrides:
        hashCode in class java.lang.Object
        Returns:
        a suitable hash code