Uploaded image for project: 'Commons Lang'
  1. Commons Lang
  2. LANG-1034

Add support for recursive comparison to EqualsBuilder#reflectionEquals

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 3.6
    • lang.builder.*
    • None

    Description

      The current implementation of EqualsBuilder.reflectionEquals() uses object equality to test reference fields found in the class. It may be helpful to offer a method that recursively builds .equals() methods for each field and uses that to perform the comparison.

      This functionality could be further extended by accepting a list of classes to include/exclude. Classes that are excluded would use the normal object equality.

      Attachments

        1. LANG-1034.1.patch
          18 kB
          yathos GmbH

        Issue Links

          Activity

            People

              pascalschumacher Pascal Schumacher
              dmjones500 Duncan Jones
              Votes:
              4 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: