Package org.firebirdsql.jdbc
Class InternalTransactionCoordinator.AbstractTransactionCoordinator
- java.lang.Object
-
- org.firebirdsql.jdbc.InternalTransactionCoordinator.AbstractTransactionCoordinator
-
- All Implemented Interfaces:
FBObjectListener.BlobListener
,FBObjectListener.StatementListener
- Enclosing class:
- InternalTransactionCoordinator
public abstract static class InternalTransactionCoordinator.AbstractTransactionCoordinator extends java.lang.Object implements FBObjectListener.StatementListener, FBObjectListener.BlobListener
-
-
Field Summary
Fields Modifier and Type Field Description protected FBConnection
connection
protected FirebirdLocalTransaction
localTransaction
protected java.util.Collection<FBStatement>
statements
-
Constructor Summary
Constructors Modifier Constructor Description protected
AbstractTransactionCoordinator(FBConnection connection, FirebirdLocalTransaction localTransaction)
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description abstract void
commit()
protected void
completeStatements(CompletionReason reason)
void
ensureTransaction()
FBConnection
getConnection()
Get the connection which owns this coordinator.protected java.util.Collection<FBStatement>
getStatements()
abstract void
rollback()
protected void
setStatements(java.util.Collection<FBStatement> statements)
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.firebirdsql.jdbc.FBObjectListener.BlobListener
executionCompleted, executionStarted
-
Methods inherited from interface org.firebirdsql.jdbc.FBObjectListener.StatementListener
executionStarted, statementClosed, statementCompleted, statementCompleted
-
-
-
-
Field Detail
-
localTransaction
protected final FirebirdLocalTransaction localTransaction
-
connection
protected final FBConnection connection
-
statements
protected final java.util.Collection<FBStatement> statements
-
-
Constructor Detail
-
AbstractTransactionCoordinator
protected AbstractTransactionCoordinator(FBConnection connection, FirebirdLocalTransaction localTransaction)
-
-
Method Detail
-
getConnection
public final FBConnection getConnection() throws java.sql.SQLException
Get the connection which owns this coordinator.- Specified by:
getConnection
in interfaceFBObjectListener.StatementListener
- Returns:
- instance of
FBConnection
- Throws:
java.sql.SQLException
- if something went wrong.
-
getStatements
protected final java.util.Collection<FBStatement> getStatements()
-
setStatements
protected final void setStatements(java.util.Collection<FBStatement> statements)
-
completeStatements
protected void completeStatements(CompletionReason reason) throws java.sql.SQLException
- Throws:
java.sql.SQLException
-
ensureTransaction
public void ensureTransaction() throws java.sql.SQLException
- Throws:
java.sql.SQLException
-
commit
public abstract void commit() throws java.sql.SQLException
- Throws:
java.sql.SQLException
-
rollback
public abstract void rollback() throws java.sql.SQLException
- Throws:
java.sql.SQLException
-
-