org.hibernate.resource.transaction.backend.jta.internal.JtaTransactionAdapter Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of hibernate-core Show documentation
Show all versions of hibernate-core Show documentation
JPMS Module-Info's for a few of the Jakarta Libraries just until they add them in themselves
/*
* Hibernate, Relational Persistence for Idiomatic Java
*
* License: GNU Lesser General Public License (LGPL), version 2.1 or later.
* See the lgpl.txt file in the root directory or .
*/
package org.hibernate.resource.transaction.backend.jta.internal;
import org.hibernate.resource.transaction.spi.TransactionStatus;
/**
* Adapter for abstracting the physical means of interacting with JTA transactions.
*
* JTA transactions can concretely be interacted with through {@link jakarta.transaction.UserTransaction}
* or {@link jakarta.transaction.Transaction} depending on environment and situation. This adapter hides
* this difference.
*
* @author Steve Ebersole
*/
public interface JtaTransactionAdapter {
/**
* Call begin on the underlying transaction object
*/
void begin();
/**
* Call commit on the underlying transaction object
*/
void commit();
/**
* Call rollback on the underlying transaction object
*/
void rollback();
TransactionStatus getStatus();
void markRollbackOnly();
void setTimeOut(int seconds);
}