velocity-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From lloyd <>
Subject "Could not determine type of iterator in #foreach loop"
Date Tue, 13 Aug 2002 11:39:20 GMT
I have a custom collection class named SparseList that returns a custom 
iterator.  When I try to use it in Velocity, I get this message in the log:

[warn] Could not determine type of iterator in #foreach loop for
        $revs at [25,57] in template revenues2.vm

The iterator is implemented as a private inner class of the collection, 
and an Iterator interface to it is returned to clients.  Do classes that 
implement Iterator to be used by Velocity have to be public?

I'd test it but don't have to code with me at the moment.  In the 
meantime - in general, are there any rules custom iterators must follow 
in order to work with Velocity?

To unsubscribe, e-mail:   <>
For additional commands, e-mail: <>

View raw message