All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.hibernate.engine.spi.SessionOwner Maven / Gradle / Ivy

There is a newer version: 7.0.0.Alpha1
Show newest version
/*
 * 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.engine.spi;

import org.hibernate.resource.transaction.backend.jta.internal.synchronization.AfterCompletionAction;
import org.hibernate.resource.transaction.backend.jta.internal.synchronization.ExceptionMapper;
import org.hibernate.resource.transaction.backend.jta.internal.synchronization.ManagedFlushChecker;

/**
 * The contract for a Session owner.  Typically this is something that wraps the Session.
 *
 * @author Gail Badner
 *
 * @see SessionBuilderImplementor#owner
 *
 * @deprecated (since 5.2) since consolidating hibernate-entitymanager into hibernate-core
 * I believe this is no longer needed.
 */
@Deprecated
public interface SessionOwner {
	/**
	 * Should session automatically be closed after transaction completion?
	 *
	 * @return {@literal true}/{@literal false} appropriately.
	 */
	boolean shouldAutoCloseSession();

	ExceptionMapper getExceptionMapper();

	AfterCompletionAction getAfterCompletionAction();

	ManagedFlushChecker getManagedFlushChecker();
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy