Uploaded image for project: 'Velocity'
  1. Velocity
  2. VELOCITY-871

#foreach should work over any Iterable class

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 1.7
    • Fix Version/s: 1.7.x, 1.x, 2.0
    • Component/s: Engine
    • Labels:
      None

      Description

      The current code was written before Java 1.5 added the Iterable class, so it tries to partially add support for it by invoking the iterator method through reflection, but this doesn't work for inaccessible classes (see VELOCITY-870). Since 1.7 requires Java 1.5, we can check if the target object implements Iterable directly.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                sdumitriu Sergiu Dumitriu
                Reporter:
                sdumitriu Sergiu Dumitriu
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: