public class DefaultSessionUtils extends Object implements SessionUtils
| Constructor and Description |
|---|
DefaultSessionUtils() |
| Modifier and Type | Method and Description |
|---|---|
<V> V |
withManualFlush(java.util.function.Supplier<V> supplier)
Converts the flush mode for the current session factory to MANUAL
for the duration of the call to the given supplier.
|
<V> V |
withReadOnlyTransaction(java.util.function.Supplier<V> supplier)
Invokes the given supplier within the context of a read-only transaction.
|
<V> V |
withTransaction(java.util.function.Supplier<V> supplier)
Invoked the given supplier within the context of a transaction.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitwithManualFlush, withReadOnlyTransaction, withTransactionpublic <V> V withTransaction(java.util.function.Supplier<V> supplier)
SessionUtilswithTransaction in interface SessionUtilsV - type returned by the suppliersupplier - supplier to invokepublic <V> V withReadOnlyTransaction(java.util.function.Supplier<V> supplier)
SessionUtilswithReadOnlyTransaction in interface SessionUtilsV - type returned by the suppliersupplier - supplier to invokepublic <V> V withManualFlush(java.util.function.Supplier<V> supplier)
SessionUtilswithManualFlush in interface SessionUtilsV - type returned by the suppliersupplier - supplier to invokeCopyright © 2022. All rights reserved.