Class GcDbAccess.ConnectionBean
java.lang.Object
edu.internet2.middleware.grouperClient.jdbc.GcDbAccess.ConnectionBean
- Enclosing class:
- GcDbAccess
returned from connection call
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic void
closeIfStarted
(GcDbAccess.ConnectionBean connectionBean) close the connection if startedboolean
if the connection was started or reused from threadlocalboolean
if we are in a transactionboolean
if a transaction was startedvoid
setConnection
(Connection connection1) void
setConnectionStarted
(boolean connectionStarted1) void
setInTransaction
(boolean inTransaction1) if we are in a transactionvoid
setTransactionStarted
(boolean transactionStarted1) if a transaction was startedstatic void
transactionEnd
(GcDbAccess.ConnectionBean connectionBean, GcTransactionEnd transactionEnd, boolean endOnlyIfStarted, boolean errorIfNoTransaction, boolean endTransaction) end a transaction
-
Constructor Details
-
ConnectionBean
public ConnectionBean()
-
-
Method Details
-
isInTransaction
public boolean isInTransaction()if we are in a transaction- Returns:
- the inTransaction
-
setInTransaction
public void setInTransaction(boolean inTransaction1) if we are in a transaction- Parameters:
inTransaction1
- the inTransaction to set
-
getConnection
- Returns:
- the connection
-
setConnection
- Parameters:
connection1
- the connection to set
-
isTransactionStarted
public boolean isTransactionStarted()if a transaction was started- Returns:
- the transactionStarted
-
setTransactionStarted
public void setTransactionStarted(boolean transactionStarted1) if a transaction was started- Parameters:
transactionStarted1
- the transactionStarted to set
-
isConnectionStarted
public boolean isConnectionStarted()if the connection was started or reused from threadlocal- Returns:
- the connectionStarted
-
setConnectionStarted
public void setConnectionStarted(boolean connectionStarted1) - Parameters:
connectionStarted1
- the connectionStarted to set
-
transactionEnd
public static void transactionEnd(GcDbAccess.ConnectionBean connectionBean, GcTransactionEnd transactionEnd, boolean endOnlyIfStarted, boolean errorIfNoTransaction, boolean endTransaction) end a transaction- Parameters:
connectionBean
-transactionEnd
-endOnlyIfStarted
- only a connection and just end it with commit...errorIfNoTransaction
-endTransaction
-
-
closeIfStarted
close the connection if started- Parameters:
connectionBean
-
-