public static boolean isUncommitted ( Transaction tx ) { if ( tx == null ) return false ; try { int status = tx . getStatus ( ) ; return status == Status . STATUS_ACTIVE || status == Status . STATUS_MARKED_ROLLBACK ; } catch ( SystemException error ) { throw new RuntimeException ( "Error during isUncommitted()" , error ) ; } }
Is the transaction uncommitted