Uploaded image for project: 'Jackrabbit Content Repository'
  1. Jackrabbit Content Repository
  2. JCR-1537

ClassDescriptor.hasIdField() fails if id is declared in upper class

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 1.5
    • 1.5
    • jackrabbit-ocm
    • None
    • Mac OS X, JVM 1.5

    Description

      org.apache.jackrabbit.ocm.mapper.model.ClassDescriptor.hasIdField() looks up only current class and not the whole hierarchy, so it fails when the id field is declared in a upper class.

      hasIdField should use getIdFieldDescriptor and not access idFieldDescriptor field directly, as follows :

      public boolean hasIdField()

      { return (this.getIdFieldDescriptor() != null && this .getIdFieldDescriptor().isId()); }

      Please find patch enclosed.

      Sincerely yours,

      Stéphane Landelle

      Attachments

        1. jackrabbit-ocm.patch
          0.5 kB
          Stephane Landelle

        Activity

          People

            clombart Christophe Lombart
            kalished Stephane Landelle
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Time Tracking

                Estimated:
                Original Estimate - 1m
                1m
                Remaining:
                Remaining Estimate - 1m
                1m
                Logged:
                Time Spent - Not Specified
                Not Specified