[jboss-user] [JBoss Seam] - Re: @RequestParameter issue

Sammy8306 do-not-reply at jboss.com
Tue May 1 07:42:29 EDT 2007


I think there's a little misunderstanding... indeed, the conversion is working just fine when I do:

/app/somepage.xhtml?id=1

which is convertible (by parseLong() I guess) to Long and therefore assignable to this field:


  | @RequestParameter("id")
  | private Long id;
  | 

However, my problem is with something like this:

/app/somepage.xhtml?id=a

Now, a NumberFormatException is raised in the convertor. I would like to gracefully fail (display a nice error message  or something). The question is whether this is possible (without explicitly doing the conversion my self)




View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4042051#4042051

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4042051



More information about the jboss-user mailing list