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

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

Introduction

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

Prototype

Propagation REQUIRED

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

Click Source Link

Document

Support a current transaction, create a new one if none exists.

Usage

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

@Override
@Transactional(propagation = Propagation.REQUIRED)
public MedicalEquipment remove(MedicalEquipment entity) {

    return null;
}

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

@Override
@Transactional(propagation = Propagation.REQUIRED)
public MonthlyPayments remove(MonthlyPayments entity) {

    return null;
}

From source file:com.karriem.tp2.immutable_domain_model_assignment.Service.Crud.EmployeesCrud.Impl.MaintenanceCrudServiceImpl.java

@Override
@Transactional(propagation = Propagation.REQUIRED)
public MaintenancePersonal remove(MaintenancePersonal entity) {

    return null;
}

From source file:cs544.wamp_blog_engine.service.impl.UserService.java

@Transactional(propagation = Propagation.REQUIRED)
@Override//from  w  w w  .  j  a v a2 s.c  om
public void addUser(User user) {

    try {
        this.userDAO.addUser(user);
    } catch (Exception e) {
        e.printStackTrace();
    }

}

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

@Override
@Transactional(propagation = Propagation.REQUIRED)
public GeneralTreatments remove(GeneralTreatments entity) {

    return null;
}

From source file:com.karriem.tp2.immutable_domain_model_assignment.Service.Crud.EmployeesCrud.Impl.GeneralStaffCrudServiceImpl.java

@Override
@Transactional(propagation = Propagation.REQUIRED)
public GeneralStaffPersonal remove(GeneralStaffPersonal entity) {

    return null;
}

From source file:dao.DAOVia.java

/**
 * /*w  w  w  . j  a v a 2 s .  c o m*/
 * @param _via 
 */
@Transactional(propagation = Propagation.REQUIRED, readOnly = false, rollbackFor = exceptionsDAO.BorrarViaException.class)
public void borrarVia(Via _via) {
    em.remove(em.merge(_via));
}

From source file:com.karriem.tp2.immutable_domain_model_assignment.Service.Crud.EmployeesCrud.Impl.CleaningStaffCrudServiceImpl.java

@Override
@Transactional(propagation = Propagation.REQUIRED)
public CleaningStaffPersonal remove(CleaningStaffPersonal entity) {

    return null;
}

From source file:com.xinferin.dao.DAOProductImpl.java

@Override
@Transactional(propagation = Propagation.REQUIRED, rollbackFor = Exception.class)
public void add(Product product) {

    // generate the private and public keys and then store them in the database.
    LicenceGenerator lg = new LicenceGenerator(null);
    product.setLicence_params(lg.getEncodedPrivateKey());
    product.setTemp(lg.getEncodedToXMLPublicKey());

    String sql = "INSERT INTO product (id, name, licence_params, temp)"
            + " VALUES (:id, :name, :licence_params, :temp)";

    SqlParameterSource sqlParameters = new BeanPropertySqlParameterSource(product);
    jdbcTemplate.update(sql, sqlParameters);
}

From source file:de.crowdcode.bitemporal.example.PersonServiceImpl.java

@Override
@Transactional(propagation = Propagation.REQUIRED)
public Person createPerson(Person person) {
    Person personCreated = personRepository.save(person);
    return personCreated;
}