Re: ValueEncoder throwing Exceptions

2010-10-12 Thread Thiago H. de Paula Figueiredo
On Tue, 12 Oct 2010 08:11:31 -0300, Stephan Windmüller wrote: On 11.10.2010 20:28, Thiago H. de Paula Figueiredo wrote: No, and I am unsure about how to use it. As far as I can see, the implementation of the ValueEncoder interface does not permit throwing Exceptions. Any RuntimeException or

Re: ValueEncoder throwing Exceptions

2010-10-12 Thread Stephan Windmüller
On 11.10.2010 20:28, Thiago H. de Paula Figueiredo wrote: >> No, and I am unsure about how to use it. As far as I can see, the >> implementation of the ValueEncoder interface does not permit throwing >> Exceptions. > Any RuntimeException or subclass can be thrown in any method of any class > or

Re: ValueEncoder throwing Exceptions

2010-10-11 Thread Thiago H. de Paula Figueiredo
On Mon, 11 Oct 2010 15:20:37 -0300, Stephan Windmüller wrote: On 11.10.2010 15:00, Thiago H. de Paula Figueiredo wrote: My thought was to contribute a custom ValueEncoder and use void onActivate(Thing thing) instead. But as far as I can see there is no way to handle the NotFoundException wh

Re: ValueEncoder throwing Exceptions

2010-10-11 Thread Stephan Windmüller
On 11.10.2010 15:00, Thiago H. de Paula Figueiredo wrote: >> My thought was to contribute a custom ValueEncoder and use >> void onActivate(Thing thing) >> instead. But as far as I can see there is no way to handle the >> NotFoundException which should be thrown for illegal IDs. Is there a way >> t

Re: ValueEncoder throwing Exceptions

2010-10-11 Thread Stephan Windmüller
On 11.10.2010 17:22, Kalle Korhonen wrote: > How do you want to handle it? onException works if you want to manage > the exception per page, I want to throw the exception and handle it in the ExceptionReport page, just like the current solution. Regards Stephan

Re: ValueEncoder throwing Exceptions

2010-10-11 Thread Kalle Korhonen
How do you want to handle it? onException works if you want to manage the exception per page, perhaps also Tynamo's exceptionpage module could be of use (http://tynamo.org/tapestry-exceptionpage+guide). Kalle On Mon, Oct 11, 2010 at 5:40 AM, Stephan Windmüller wrote: > Hello! > > Currently we h

Re: ValueEncoder throwing Exceptions

2010-10-11 Thread Thiago H. de Paula Figueiredo
On Mon, 11 Oct 2010 09:40:01 -0300, Stephan Windmüller wrote: Hello! Hi! Currently we have a lot of onActivate/Passivate calls of the form void onActivate(String thingId) throws NotFoundException{ this.thing = myService.getThing(thingId); } My thought was to contribute a custom