[
https://issues.apache.org/jira/browse/VELOCITY-443?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12533343
]
Henning Schmiedehausen commented on VELOCITY-443:
-------------------------------------------------
That implies that iterator() always returns an Iterator object which might lead
to hard-to-find ClassCastExceptions. I'd appreciate a catch (ClassCastException
) with a meaningful error message. Apart from that: Nice.
> Velocity 1.4 does not support Iterable collections.
> ---------------------------------------------------
>
> Key: VELOCITY-443
> URL: https://issues.apache.org/jira/browse/VELOCITY-443
> Project: Velocity
> Issue Type: Improvement
> Affects Versions: 1.4
> Environment: Java 5
> Reporter: Peter Lawrey
> Assignee: Nathan Bubna
> Priority: Minor
> Fix For: 1.6
>
>
> In the new for loop in Java 5 e.g.
> for(Object obj: iterable)
> the collection iterated only needs to be of type Iterable
> However, In Velocity a foreach loop must be either a Collection or a Map but
> cannot be just an Iterable.
> Suggestion, support Iterable containers.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]