[ http://issues.apache.org/jira/browse/VELOCITY-219?page=all ]
Henning Schmiedehausen resolved VELOCITY-219.
---------------------------------------------
Resolution: Invalid
Ok, after some debugging and code browsing, I'm a bit confused.
The ArrayList object comes out of ASTObjectArray#value() (for the normal array
case) or ASTIntegerRange#value() for the range ([1..10]) case. They both create
an ArrayList object. However, the actual API *is* Object
value(InternalContextAdapter context), so there is no guarantee that this will
be any assumed type anyway.
We do have not a single method (at least none that I could find) that returns
an explicit ArrayList anywhere. We have a very very small number of explicit
ArrayList variable declarations that I will change to List. But aside from that
I see nothing that we could/must change for API 2.0.
If you have more information, please reopen that issue. Thanks.
> Velocity list operator should return a Java List reference rather than
> ArrayList reference
> ------------------------------------------------------------------------------------------
>
> Key: VELOCITY-219
> URL: http://issues.apache.org/jira/browse/VELOCITY-219
> Project: Velocity
> Issue Type: Improvement
> Components: Engine
> Affects Versions: 1.4
> Environment: Operating System: All
> Platform: All
> Reporter: Daniel Rall
> Priority: Minor
> Fix For: 1.5
>
>
> In the 1.x releases of Velocity, the list operator [] returns an ArrayList
> reference instead of a List reference. In the future (2.x), a cleaner API
> would
> be to return a List reference.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]