Example usage for org.springframework.transaction.annotation Propagation SUPPORTS

List of usage examples for org.springframework.transaction.annotation Propagation SUPPORTS

Introduction

In this page you can find the example usage for org.springframework.transaction.annotation Propagation SUPPORTS.

Prototype

Propagation SUPPORTS

To view the source code for org.springframework.transaction.annotation Propagation SUPPORTS.

Click Source Link

Document

Support a current transaction, execute non-transactionally if none exists.

Usage

From source file:com.karriem.tp2.immutable_domain_model_assignment.Service.Crud.EquipmentCrud.Impl.MedicalEquipmentCrudServiceImpl.java

@Override
@Transactional(propagation = Propagation.SUPPORTS)
public MedicalEquipment find(String id) {

    return null;
}

From source file:com.karriem.tp2.immutable_domain_model_assignment.Service.Crud.TreatmentCrud.Impl.GeneralTreatmentCrudServiceImpl.java

@Override
@Transactional(propagation = Propagation.SUPPORTS)
public GeneralTreatments find(String id) {

    return null;
}

From source file:com.karriem.tp2.immutable_domain_model_assignment.Service.Crud.PaymentMethodCrud.Impl.MonthlyPaymentCrudServiceImpl.java

@Override
@Transactional(propagation = Propagation.SUPPORTS)
public MonthlyPayments find(String id) {

    return null;
}

From source file:cs425.yogastudio.service.AdminService.java

@Transactional(propagation = Propagation.SUPPORTS)
public void setRoleDAO(RoleDAO roleDAO) {
    this.roleDAO = roleDAO;
}

From source file:com.oak_yoga_studio.service.impl.ShoppingCartItemServiceImpl.java

@Transactional(propagation = Propagation.SUPPORTS)
public void setCartItemDAO(ShoppingCartItemDAO cartItemDAO) {
    this.cartItemDAO = cartItemDAO;
}

From source file:br.exemplo.service.PessoaTesteTransactionService.java

@Transactional(propagation = Propagation.SUPPORTS) //utiliza a mesma transao
public void pessoasAll() {
    System.out.println("==== SELECIONA TODOS OS DADOS DA TABELA (2) ======");
    EntityManager m = emf.createEntityManager();
    List<Pessoa> list = m.createNamedQuery("Pessoa.all", Pessoa.class).getResultList();
    for (Pessoa p : list) {
        System.out.println("ALL >> " + p);
    }//from ww w .  j  ava 2s  .  c  o m

}

From source file:com.oak_yoga_studio.service.impl.ShoppingCartServiceImpl.java

@Transactional(propagation = Propagation.SUPPORTS)
public void setCartDAO(ShoppingCartDAO cartDAO) {
    this.cartDAO = cartDAO;
}

From source file:io.cloudslang.engine.queue.services.QueueStateIdGeneratorServiceImpl.java

@Transactional(propagation = Propagation.SUPPORTS)
@Override
public Long generateStateId() {
    return (Long) identityGenerator.next();
}

From source file:com.oak_yoga_studio.dao.impl.SectionDAOImpl.java

@Transactional(propagation = Propagation.SUPPORTS)
@Override
public void updateSection(Section section) {

    sf.getCurrentSession().saveOrUpdate(section);
}

From source file:com.oak_yoga_studio.dao.impl.OrderDAOImpl.java

@Transactional(propagation = Propagation.SUPPORTS)
@Override/*from  ww  w . j ava  2 s  .  c  om*/
public Order getOrder(int id) {
    Order order = (Order) sf.getCurrentSession().get(Order.class, id);
    return order;
}