public synchronized boolean close() throws TTException {
        waitForRunningCommit();
        if (!mClosed) {
            // Forcibly close all open transactions.
            for (final IBucketReadTrx rtx : mBucketTrxs) {
                // If the transaction is a WriteTrx, clear log aswell..
                if (rtx instanceof BucketWriteTrx) {
                    ((BucketWriteTrx)rtx).clearLog();
                }
                rtx.close();
            }

            // Immediately release all resources.
            mLastCommittedUberBucket = null;
            mBucketTrxs.clear();
            mResourceConfig.mBackend.close();
            mDatabase.mSessions.remove(mSessionConfig.getResource());
            mClosed = true;
            return true;
        } else {
            return false;
        }
    }
public synchronized boolean close ( ) throws TTException { waitForRunningCommit ( ) ; if ( ! mClosed ) { for ( final IBucketReadTrx rtx : mBucketTrxs ) { if ( rtx instanceof BucketWriteTrx ) { ( ( BucketWriteTrx ) rtx ) . clearLog ( ) ; } rtx . close ( ) ; } mLastCommittedUberBucket = null ; mBucketTrxs . clear ( ) ; mResourceConfig . mBackend . close ( ) ; mDatabase . mSessions . remove ( mSessionConfig . getResource ( ) ) ; mClosed = true ; return true ; } else { return false ; } }
{@inheritDoc}