You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@velocity.apache.org by Nathan Bubna <na...@esha.com> on 2002/07/02 23:23:33 UTC
[Veltools] ParameterParser patch
Nathan said:
> I've also been working on my search result paging tool. I should have
> something to contribute there shortly. I also intend to get into the
whole
> ParameterParser mess again soon. :-)
...and so i did. i went through it and:
-de-staticized (is that a word?) the parsing methods
-implemented ViewTool so it can be conveniently used as a view tool
-added an alternate constructor for convenience in non-template situations
-changed getNumber (and thereby it's dependents) to catch NFE's and return
null instead
i think these changes should make this class immensely easier to use at a
miniscule cost to performance. yes, it is no longer safe to use as an
application or session scoped tool, but IMO it is intrinsically
request-scope (it exists only to parse request parameters!) and should be
used as such.
the patch for these changes is attached.
thanks!
Nathan Bubna
nathan@esha.com