[jboss-dev-forums] [Design the new POJO MicroContainer] - Re: Use of Throwable in method signatures
scott.stark@jboss.org
do-not-reply at jboss.com
Wed Jul 12 13:10:17 EDT 2006
The Throwable just results in is a boilerplate code block like the following that does not actually require handling of the runtime errors:
| try
| {
| kernelDeployer = new BasicXMLDeployer(context.getKernel());
| }
| catch(Error e)
| {
| throw e;
| }
| catch(Exception e)
| {
| throw e;
| }
| catch(Throwable e)
| {
| // Should not happen
| throw new Exception("Failed to create BasicXMLDeployer", e);
| }
|
This still does not really solve the problem you are after as I have ignored the runtime exceptions/errors as before. It seems what we really need is a KernelAction wrapper similar to a PriviledgedAction that integrates with the caller's kernel state to ensure exceptions are properly reflected in the state machine. I don't see how to force use of this though.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3957429#3957429
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3957429
More information about the jboss-dev-forums
mailing list