Skip to main content



      Home
Home » Eclipse Projects » Rich Client Platform (RCP) » Error Handling
Error Handling [message #449168] Wed, 10 May 2006 15:47 Go to next message
Eclipse UserFriend
Im doing my RCP application and I want to write in 1 place a generic error
handling method.

Where should I put this ?

in the WorkbenchAdvisor ?
in WorkbenchWindowAdvisor ?

regards
RA
Re: Error Handling [message #449186 is a reply to message #449168] Thu, 11 May 2006 01:12 Go to previous messageGo to next message
Eclipse UserFriend
Hi Rodrigo,

we've had the same problem. Unfortunately there are several places where
you have to handle uncaught exceptions.
1. Uncaught EventLoop Exceptions are passed to the WorkbenchAdvisor
2. Eclipse makes heavy use of so called ISafeRunnable. When these fail
their runner will be notified. You can register your own
SafeRunnableRunner with SafeRunnable.setRunner(ISaveRunnableRunner)
3. At this time you have no chance of getting a grip of the expcetion
when Jobs fail. See and vote for Bug 111852
https://bugs.eclipse.org/bugs/show_bug.cgi?id=111852

There might be more ...

We've already developed an exception handler that allows registration of
handlers by extension-point and code. It's already hooked in all places
we could find to handle errors. You might want to have a look or reuse
this, its LGPL. SVN:
https://svn.jfire.org/svn/main/trunk/org.nightlabs.base the the package
org.nightlabs.base.exceptionhandler

Best regards
Alex




Rodrigo Asensio wrote:
> Im doing my RCP application and I want to write in 1 place a generic
> error handling method.
>
> Where should I put this ?
>
> in the WorkbenchAdvisor ?
> in WorkbenchWindowAdvisor ?
>
> regards
> RA
>
>
>
Re: Error Handling [message #449251 is a reply to message #449186] Thu, 11 May 2006 09:12 Go to previous message
Eclipse UserFriend
Cool, thanks

I use to have a framework built over Swing, and now Im starting write one
over swt. I use to have too a ActionListener implementation who throws
Exception and it was captured and handled internally. Maybe I can do that
aproach. But I still have to study in deep user actions in swt.

thanks a lot

RA
Previous Topic:Preferred size for a sticky view
Next Topic:How to create a editor for a new perspective
Goto Forum:
  


Current Time: Sun Aug 31 02:15:48 EDT 2025

Powered by FUDForum. Page generated in 0.02748 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top