Example usage for javax.persistence CascadeType ALL

List of usage examples for javax.persistence CascadeType ALL

Introduction

In this page you can find the example usage for javax.persistence CascadeType ALL.

Prototype

CascadeType ALL

To view the source code for javax.persistence CascadeType ALL.

Click Source Link

Document

Cascade all operations

Usage

From source file:com.hmsinc.epicenter.model.health.Patient.java

@OneToMany(cascade = { CascadeType.ALL }, fetch = FetchType.LAZY, mappedBy = "patient")
@Sort(type = SortType.NATURAL)/* w  w  w .j  a v a2s . co m*/
public SortedSet<PatientDetail> getPatientDetails() {
    return this.patientDetails;
}

From source file:gov.nih.nci.protexpress.domain.experiment.ExperimentRun.java

/**
 * Gets the protocolApplications.//from  ww  w  . java2  s.  com
 *
 * @return the protocolApplications.
 */
@OneToMany(mappedBy = "experimentRun", fetch = FetchType.LAZY, cascade = CascadeType.ALL)
public List<ProtocolApplication> getProtocolApplications() {
    return this.protocolApplications;
}

From source file:com.hmsinc.epicenter.model.health.Interaction.java

@ManyToOne(cascade = { CascadeType.ALL }, fetch = FetchType.LAZY)
@JoinColumn(name = "ID_PATIENT_DETAIL", unique = false, nullable = false, insertable = true, updatable = true)
@org.hibernate.annotations.ForeignKey(name = "FK_INTERACTION_3")
public PatientDetail getPatientDetail() {
    return this.patientDetail;
}

From source file:de.pro.dbw.file.reflection.api.ReflectionModel.java

@OneToMany(cascade = CascadeType.ALL, fetch = FetchType.LAZY)
@JoinTable(name = JOIN_TABLE__NAME__MAPPING_REFLECTION_COMMENT, joinColumns = @JoinColumn(name = IReflectionCommentConfiguration.REFLECTION_COMMENT_MODEL__COLUMN_NAME__ID), inverseJoinColumns = @JoinColumn(name = IReflectionCommentConfiguration.REFLECTION_COMMENT_MODEL__COLUMN_NAME__ID))
public List<ReflectionCommentModel> getReflectionCommentModels() {
    if (reflectionCommentModelsProperty == null) {
        return _reflectionCommentModels;
    } else {/*from   w  w w. j  a v  a 2  s.  c o  m*/
        return (List<ReflectionCommentModel>) reflectionCommentModelsProperty.getValue();
    }
}

From source file:com.hmsinc.epicenter.model.workflow.Event.java

/**
 * @return the organization/*  w  ww .j  ava2  s.co  m*/
 */
@ManyToOne(cascade = { CascadeType.ALL }, fetch = FetchType.LAZY)
@JoinColumn(name = "ID_ORGANIZATION", unique = false, nullable = false, insertable = true, updatable = true)
@ForeignKey(name = "FK_EVENT_1")
@Cache(usage = CacheConcurrencyStrategy.NONSTRICT_READ_WRITE)
public Organization getOrganization() {
    return organization;
}

From source file:org.tsm.concharto.model.Event.java

@ManyToMany(cascade = { CascadeType.ALL })
@Cascade({ org.hibernate.annotations.CascadeType.SAVE_UPDATE,
        org.hibernate.annotations.CascadeType.DELETE_ORPHAN })
@ForeignKey(name = "FK_EVENT_USERTAG", inverseName = "FK_USERTAG_EVENT")
public List<UserTag> getUserTags() {
    return userTags;
}

From source file:com.netspective.medigy.model.party.PostalAddress.java

@OneToMany(cascade = CascadeType.ALL)
@JoinColumn(name = "contact_mech_id")
public Set<PostalAddressBoundary> getAddressBoundaries() {
    return addressBoundaries;
}

From source file:com.jasperreports.hrdb.Employee.java

@OneToMany(fetch = FetchType.LAZY, cascade = CascadeType.ALL, mappedBy = "employee")
public List<Vacation> getVacations() {
    return this.vacations;
}

From source file:onl.netfishers.netshot.device.DeviceGroup.java

/**
 * Gets the applied hardware rules.//from   w  w  w  . j  a v a 2  s .c  o m
 *
 * @return the applied hardware rules
 */
@OneToMany(cascade = CascadeType.ALL, mappedBy = "targetGroup")
public Set<HardwareRule> getAppliedHardwareRules() {
    return appliedHardwareRules;
}

From source file:org.apromore.dao.model.ProcessModelVersion.java

@OneToOne(cascade = CascadeType.ALL)
@JoinColumn(name = "nativeId", referencedColumnName = "id")
public Native getNativeDocument() {
    return this.nativeDocument;
}