Re: Attempt for an UNO Undo API

Frank Schönheit <[email protected]>
Newsgroups gmane.comp.openoffice.devel.api
Message-ID <[email protected]>
Hi Ingrid,

> I think a new UndoFailedException is better than css.uno.Exception. A 
> client can react on this with a small cleanup of whatever UndoStack 
> related doings and than proceed further. While catching a 
> css.uno.Exception the proper reaction is much more unclear. Maybe it is 
> necessary to quit the whole process?

That's something I'd expect a RuntimeException to be used for (though
... seeing the number of RuntimeExceptions thrown during normal
operation of OOo, this argument isn't too valid. Which could bring us
back to "missing exception specifications in our API designs", if we
really wanted to ...).

In reacting on the error during Undo, I don't see a real difference
between "Exception" and a specific "UndoFailedException". However, in
using the API, and maybe propagating exceptions up the stack, a specific
exception is slightly better for knowing what went wrong than a generic
one, I'd say.

Ciao
Frank

-- 
ORACLE
Frank Schönheit | Software Engineer | [email protected]
Oracle Office Productivity: http://www.oracle.com/office
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.