public class SavePointWork<R> extends Object implements ReturningWork<R>
Savepoint
is
created on the Connection
. If the parent work
results throws an SQLException
the connection is
rolled back to the savepoint. Other exceptions and a normal
completion just releases the savepoint.Modifier and Type | Field and Description |
---|---|
private ReturningWork<R> |
work |
Constructor and Description |
---|
SavePointWork(ReturningWork<R> work)
Create a new work item.
|
Modifier and Type | Method and Description |
---|---|
R |
execute(Connection connection)
From the Work interface
-----------------------
|
private final ReturningWork<R> work
public SavePointWork(ReturningWork<R> work)
work
- The parent workpublic R execute(Connection connection) throws SQLException
execute
in interface ReturningWork<R>
SQLException