svn-gvsig-desktop / tags / v1_1_Build_1015 / libraries / libGDBMS / src / main / java / com / hardcode / gdbms / engine / data / driver / DBTransactionalDriver.java @ 13679
History | View | Annotate | Download (985 Bytes)
1 | 3199 | fjp | package com.hardcode.gdbms.engine.data.driver; |
---|---|---|---|
2 | |||
3 | import java.sql.Connection; |
||
4 | import java.sql.SQLException; |
||
5 | |||
6 | |||
7 | |||
8 | /**
|
||
9 | * Interface to be implemented by those db drivers whose management
|
||
10 | * system support transactions
|
||
11 | *
|
||
12 | * @author Fernando Gonz?lez Cort?s
|
||
13 | */
|
||
14 | public interface DBTransactionalDriver { |
||
15 | /**
|
||
16 | * Begins a transaction
|
||
17 | * @param newParam TODO
|
||
18 | *
|
||
19 | * @throws SQLException If the transaction could not be started
|
||
20 | */
|
||
21 | public void beginTrans(Connection con) throws SQLException; |
||
22 | |||
23 | /**
|
||
24 | * Commits the changes made during the transaction
|
||
25 | * @param con TODO
|
||
26 | *
|
||
27 | * @throws SQLException If the transaction could not be commited
|
||
28 | */
|
||
29 | public void commitTrans(Connection con) throws SQLException; |
||
30 | |||
31 | /**
|
||
32 | * Cancels the changes made during the transaction
|
||
33 | * @param con TODO
|
||
34 | *
|
||
35 | * @throws SQLException If the transaction could not be cancelled
|
||
36 | */
|
||
37 | public void rollBackTrans(Connection con) throws SQLException; |
||
38 | |||
39 | } |