|
From: Geoffrey De S. <ge0...@gm...> - 2008-01-30 08:16:11
|
Forms are ussually meant for domain objects or transfer objects. Just like it's pretty impossible to try to jpa-persist a (heavy) business service or DAO instance. Wouldn't the use case you describe be better off if you initialize the encodedBody before showing the form? With kind regards, Geoffrey De Smet Rogan Dawes schreef: > Hi folks, > > I am trying to deal with a derived property that can throw an exception > when set (or even when "get"). > > The method signature is: > > byte[] getEncodedBody() throws IOException; > void setEncodedBody(byte[] body) throws IOException; > > As suggested, there are some cases where invalid data will cause an > IOException to be thrown. When this happens, I get "methodInvocation" > showing up in my form message area. > > Is there some way of handling this exception, and propagating the > underlying exception to the user? This appears to be handled somewhere > in the BeanPropertyAccessStrategy or BeanWrapperImpl, although I can't > see exactly where. > > Any ideas? > > Rogan > > ------------------------------------------------------------------------- > This SF.net email is sponsored by: Microsoft > Defy all challenges. Microsoft(R) Visual Studio 2008. > http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ |