Rickard �berg wrote:
> I have a property which is of type long. I try to set it using this
> syntax:
> $foo.setValue(123)
>
> But it doesn't work. If I change the property to type int, it works. Is
> this a limitation of Velocity, or am I doing something wrong?
I think I found it. In ASTReference.setValue() the code only checks for
integer set-methods (since ASTNumberLiteral will always produce an
Integer). The setValue code should be modified to handle this case.
Preferably it should check for all Number-type methods and convert the
ASTNumberLiteral to whatever Number-type is to be used.
Either that or introduce some casting possibilities. The magical convert
is better though I think.
/Rickard
--
Rickard �berg
Software Development Specialist
xlurc - Xpedio Link�ping Ubiquitous Research Center
Author of "Mastering RMI"
Email: [EMAIL PROTECTED]