Class TransactionUtils


  • public class TransactionUtils
    extends java.lang.Object
    Utility methods relating to transactions.
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static java.lang.String getNameForTransactionIsolationLevel​(int isolation)
      Accessor for a string name of a transaction isolation level.
      static java.lang.String getTransactionIsolationForStoreManager​(StoreManager storeMgr, java.lang.String transactionIsolation)
      Method to return the transaction isolation level that will be used for the provided StoreManager bearing in mind the specified level the user requested.
      static int getTransactionIsolationLevelForName​(java.lang.String isolationName)
      Convenience method to convert the supplied isolation level name into the associated UserTransaction type number.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • TransactionUtils

        public TransactionUtils()
    • Method Detail

      • getTransactionIsolationForStoreManager

        public static java.lang.String getTransactionIsolationForStoreManager​(StoreManager storeMgr,
                                                                              java.lang.String transactionIsolation)
        Method to return the transaction isolation level that will be used for the provided StoreManager bearing in mind the specified level the user requested.
        Parameters:
        storeMgr - The Store Manager
        transactionIsolation - Requested isolation level
        Returns:
        Isolation level to use
        Throws:
        TransactionIsolationNotSupportedException - When no suitable level available given the requested level
      • getNameForTransactionIsolationLevel

        public static java.lang.String getNameForTransactionIsolationLevel​(int isolation)
        Accessor for a string name of a transaction isolation level.
        Parameters:
        isolation - The isolation level (as defined by UserTransaction).
        Returns:
        The name
      • getTransactionIsolationLevelForName

        public static int getTransactionIsolationLevelForName​(java.lang.String isolationName)
        Convenience method to convert the supplied isolation level name into the associated UserTransaction type number.
        Parameters:
        isolationName - The name of the isolation level
        Returns:
        Isolation level type