Struts 2
  1. Struts 2
  2. WW-2333

ValueStackDataSource implementation leads to class cast exceptions

    Details

    • Type: Bug Bug
    • Status: Open
    • Priority: Major Major
    • Resolution: Unresolved
    • Affects Version/s: 2.0.11
    • Fix Version/s: 3.0
    • Component/s: Plugin - JasperReports
    • Labels:
      None

      Description

      Assume you have a class Foo that has a Collection of Bar's. Without using Struts, the expected behavior of a report that takes Foo's as input is, that a reference $F

      {bar}

      returns a java.util.Collection (of Bar's). However, this will not be the case when using the ValueStackDataSource implementation; an instance of ValueStackDataSource is returned instead of a collection. If the method "getFieldValue" gets called, it checks if the field value is iteratable (which is true for collections) and then returns a new ValueStackDataSource instead of the field value itself. I assume that this behavior breaks many reports.

        Activity

        Thorsten Schäfer created issue -
        Ted Husted made changes -
        Field Original Value New Value
        Fix Version/s Future [ 21530 ]
        Antonio Petrelli made changes -
        Workflow Struts - editable closed status [ 44700 ] Struts - editable closed status (temporary) [ 48716 ]
        Antonio Petrelli made changes -
        Workflow Struts - editable closed status (temporary) [ 48716 ] Struts - editable closed status [ 51865 ]
        Jeff Turner made changes -
        Project Import Mon Feb 01 01:17:42 UTC 2010 [ 1264987062082 ]
        Lukasz Lenart made changes -
        Fix Version/s 3.x [ 12319158 ]
        Fix Version/s Future [ 12314681 ]

          People

          • Assignee:
            Unassigned
            Reporter:
            Thorsten Schäfer
          • Votes:
            1 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:

              Development