Class SpringTransactionController

  • All Implemented Interfaces:
    org.copperengine.core.persistent.txn.TransactionController

    public class SpringTransactionController
    extends java.lang.Object
    implements org.copperengine.core.persistent.txn.TransactionController
    Implementation of the TransactionController interface that internally uses Springs Transaction Management
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      <T> T run​(org.copperengine.core.persistent.txn.DatabaseTransaction<T> txn)  
      <T> T run​(org.copperengine.core.persistent.txn.Transaction<T> txn)  
      void setDataSource​(javax.sql.DataSource dataSource)  
      void setTransactionManager​(org.springframework.transaction.PlatformTransactionManager transactionManager)  
      • Methods inherited from class java.lang.Object

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

      • SpringTransactionController

        public SpringTransactionController()
    • Method Detail

      • setTransactionManager

        public void setTransactionManager​(org.springframework.transaction.PlatformTransactionManager transactionManager)
      • setDataSource

        public void setDataSource​(javax.sql.DataSource dataSource)
      • run

        public <T> T run​(org.copperengine.core.persistent.txn.DatabaseTransaction<T> txn)
                  throws java.lang.Exception
        Specified by:
        run in interface org.copperengine.core.persistent.txn.TransactionController
        Throws:
        java.lang.Exception
      • run

        public <T> T run​(org.copperengine.core.persistent.txn.Transaction<T> txn)
                  throws java.lang.Exception
        Specified by:
        run in interface org.copperengine.core.persistent.txn.TransactionController
        Throws:
        java.lang.Exception