On Tue, Jul 26, 2011 at 2:59 PM, Christopher Schultz
<ch...@christopherschultz.net> wrote:
> All,
>
> On 7/26/2011 5:23 PM, Christopher Schultz wrote:
>> As I get further into the testing of Velocity Tools 2.0, I'm finding
>> that the addAllParameters method isn't working as it used to.
>
> Given:
>
> #set($forward = $link.relative('/foo'))
>
> WORKS: \$forward=$forward
> WORKS: \$forward.addAllParameters()=$forward.addAllParameters()
> WORKS:
> \$link.setRelative('/foo').addAllParameters()=$link.setRelative('/foo').addAllParameters()
>
> Given:
>
> #set($forward = $link.relative('/foo').addQueryData('token', 'xyz'))
>
> (Note the added "addQueryData" call)
>
> FAILS: \$forward=$forward
> FAILS: \$forward.addAllParameters()=$forward.addAllParameters()
>
> Any ideas?

No, addQueryData in the deprecated version just forwards to
append(Object,Object) in the generic version, and both clearly return
the fresh copy of the LinkTool.  So, i see no reason for those
references to fully fail unless an exception is being thrown that you
are suppressing with an event handler.  Anything in the logs?

> I don't know why using a temporary reference would have any bearing on
> the behavior. Perhaps I'm stumbling into something else and drawing the
> wrong conclusion.
>
> Thanks,
> -chris
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscr...@velocity.apache.org
For additional commands, e-mail: user-h...@velocity.apache.org

Reply via email to