mirror of
https://github.com/ebean-orm/ebean.git
synced 2024-04-21 10:51:47 +00:00
#2359 - Rename Transaction.getConnection() method to connection() with deprecation
This commit is contained in:
@@ -538,6 +538,12 @@ public interface Transaction extends AutoCloseable {
|
||||
* Examples of when a developer may wish to use the connection directly are:
|
||||
* Savepoints, advanced CLOB BLOB use and advanced stored procedure calls.
|
||||
*/
|
||||
Connection connection();
|
||||
|
||||
/**
|
||||
* Deprecated migrate to connection().
|
||||
*/
|
||||
@Deprecated
|
||||
Connection getConnection();
|
||||
|
||||
/**
|
||||
|
||||
@@ -61,7 +61,7 @@ public class SimpleSequenceIdGenerator implements PlatformIdGenerator {
|
||||
PreparedStatement pstmt = null;
|
||||
ResultSet rset = null;
|
||||
try {
|
||||
c = useTxnConnection ? t.getConnection() : dataSource.getConnection();
|
||||
c = useTxnConnection ? t.connection() : dataSource.getConnection();
|
||||
pstmt = c.prepareStatement(sql);
|
||||
rset = pstmt.executeQuery();
|
||||
if (rset.next()) {
|
||||
|
||||
Reference in New Issue
Block a user