Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8087312

PropertyMapWrapper.equals should compare className

    XMLWordPrintable

Details

    • b70
    • generic
    • generic

    Backports

      Description

        PropertyMapWrapper is a class that implements equals and hashCode on property maps to allow for reuse of maps. It currently just compares properties, but not the owning object's class. If a property map is used with different owner classes accessing any field property will result in a ClassCastException.

        I noticed this while working on JDK-8077149, but the code that triggers the ClassCastException will not be part of the fix so I'm filing a separate bug.

        Attachments

          Issue Links

            Activity

              People

                hannesw Hannes Wallnoefer
                hannesw Hannes Wallnoefer
                Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                  Created:
                  Updated:
                  Resolved: