Uploaded image for project: 'Commons JXPath'
  1. Commons JXPath
  2. JXPATH-39

DynamicPropertyHandler and Collections bug

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Blocker
    • Resolution: Fixed
    • Affects Version/s: 1.0 Final
    • Fix Version/s: None
    • Labels:
      None
    • Environment:

      Operating System: other
      Platform: All

    • Bugzilla Id:
      9336

      Description

      I possibly noticed a bug concerning dynamic property beans containing collections.

      Consider a bean, which's properties are handled thru a DynamicPropertyHandler.

      When a certain property is a (indexed) collection,
      context.iterate("/<property>") should (so far as I understood) iterate over all
      elements of the collection.
      Instead the Iterator iterates only over the first element.

      The same thing without dynamic properties works of course.

      You reproduce this behaviour by using a Map to store the attributes.

      TX
      Markus

        Activity

        Hide
        dmitri@apache.org Dmitri Plotnikov added a comment -

        Fixed a problem with DynamicPropertyPointer

        diff -r1.5 DynamicPropertyPointer.java
        196c196
        < return ValueUtils.getLength(getNodeValue());

        > return ValueUtils.getLength(getBaseValue

        Show
        dmitri@apache.org Dmitri Plotnikov added a comment - Fixed a problem with DynamicPropertyPointer diff -r1.5 DynamicPropertyPointer.java 196c196 < return ValueUtils.getLength(getNodeValue()); — > return ValueUtils.getLength(getBaseValue
        Hide
        mm@teraspect.de Markus Menner added a comment -

        Created an attachment (id=1927)
        Testcase for this bug

        Show
        mm@teraspect.de Markus Menner added a comment - Created an attachment (id=1927) Testcase for this bug

          People

          • Assignee:
            Unassigned
            Reporter:
            mm@teraspect.de Markus Menner
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development