In pseudo code:
UndoStack tx = new UndoStack(); try { Backup(tx, ...) Copy(tx, ...) Move(tx, ...) } catch (Exception) { tx.rollback(); <- process undo-stack }
This looks ok. I still prefer each command to handle it's own cleanup (try/catch/finally in part existing for this purpose), but there's nothing wrong with the concept.
I'm curious what you find out about Commons Transactions. When I looked it over, it seemd to me designed with primitives for us to use to make our own transactions. I missed any ready-to-use code for this purpose. I wonder how much overlap there is with java.util.concurrent in the new JDK 5.
Cheers, --binkley
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
