Class MockTransactionTemplate

java.lang.Object
org.springframework.transaction.support.DefaultTransactionDefinition
org.springframework.transaction.support.TransactionTemplate
com.atlassian.bamboo.spring.MockTransactionTemplate
All Implemented Interfaces:
TransactionAndHibernateTemplate, Serializable, org.springframework.beans.factory.InitializingBean, org.springframework.transaction.support.TransactionOperations, org.springframework.transaction.TransactionDefinition

public class MockTransactionTemplate extends org.springframework.transaction.support.TransactionTemplate implements TransactionAndHibernateTemplate
See Also:
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
     

    Fields inherited from class org.springframework.transaction.support.TransactionTemplate

    logger

    Fields inherited from class org.springframework.transaction.support.DefaultTransactionDefinition

    PREFIX_ISOLATION, PREFIX_PROPAGATION, PREFIX_TIMEOUT, READ_ONLY_MARKER

    Fields inherited from interface org.springframework.transaction.TransactionDefinition

    ISOLATION_DEFAULT, ISOLATION_READ_COMMITTED, ISOLATION_READ_UNCOMMITTED, ISOLATION_REPEATABLE_READ, ISOLATION_SERIALIZABLE, PROPAGATION_MANDATORY, PROPAGATION_NESTED, PROPAGATION_NEVER, PROPAGATION_NOT_SUPPORTED, PROPAGATION_REQUIRED, PROPAGATION_REQUIRES_NEW, PROPAGATION_SUPPORTS, TIMEOUT_DEFAULT
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    doWork(org.hibernate.jdbc.Work work)
     
    <T> T
    execute(org.springframework.orm.hibernate5.HibernateCallback<T> hibernateCallback)
     
    <T> T
    execute(org.springframework.transaction.support.TransactionCallback<T> action)
     
    org.hibernate.Session
     

    Methods inherited from class org.springframework.transaction.support.TransactionTemplate

    afterPropertiesSet, equals, getTransactionManager, setTransactionManager

    Methods inherited from class org.springframework.transaction.support.DefaultTransactionDefinition

    getDefinitionDescription, getIsolationLevel, getName, getPropagationBehavior, getTimeout, hashCode, isReadOnly, setIsolationLevel, setIsolationLevelName, setName, setPropagationBehavior, setPropagationBehaviorName, setReadOnly, setTimeout, toString

    Methods inherited from class java.lang.Object

    clone, finalize, getClass, notify, notifyAll, wait, wait, wait

    Methods inherited from interface org.springframework.transaction.support.TransactionOperations

    executeWithoutResult
  • Field Details

  • Constructor Details

    • MockTransactionTemplate

      public MockTransactionTemplate()
  • Method Details

    • execute

      public <T> T execute(org.springframework.transaction.support.TransactionCallback<T> action) throws org.springframework.transaction.TransactionException
      Specified by:
      execute in interface org.springframework.transaction.support.TransactionOperations
      Overrides:
      execute in class org.springframework.transaction.support.TransactionTemplate
      Throws:
      org.springframework.transaction.TransactionException
    • execute

      public <T> T execute(org.springframework.orm.hibernate5.HibernateCallback<T> hibernateCallback)
      Specified by:
      execute in interface TransactionAndHibernateTemplate
    • doWork

      public void doWork(org.hibernate.jdbc.Work work) throws org.hibernate.HibernateException
      Specified by:
      doWork in interface TransactionAndHibernateTemplate
      Throws:
      org.hibernate.HibernateException
    • getSession

      public org.hibernate.Session getSession()