Example usage for org.hibernate.annotations CascadeType ALL

List of usage examples for org.hibernate.annotations CascadeType ALL

Introduction

In this page you can find the example usage for org.hibernate.annotations CascadeType ALL.

Prototype

CascadeType ALL

To view the source code for org.hibernate.annotations CascadeType ALL.

Click Source Link

Document

Includes all types listed here.

Usage

From source file:gov.nih.nci.cabig.caaers.domain.AdditionalInformation.java

License:BSD License

/**
 * Gets the additionalInformationDocument
 *
 * @return the additional information document
 *///w ww  . j av  a 2  s . co  m
@OneToMany(mappedBy = "additionalInformation", fetch = FetchType.LAZY, orphanRemoval = true)
@Cascade(value = { CascadeType.ALL })
@Fetch(value = org.hibernate.annotations.FetchMode.SUBSELECT)
public List<AdditionalInformationDocument> getAdditionalInformationDocuments() {
    return additionalInformationDocuments;
}

From source file:gov.nih.nci.cabig.caaers.domain.AdverseEvent.java

License:BSD License

/**
 * Gets the course agent attributions.// ww w.j  av  a  2s.  com
 *
 * @return the course agent attributions
 */
@OneToMany(orphanRemoval = true)
@JoinColumn(name = "adverse_event_id", nullable = false)
@IndexColumn(name = "list_index")
@Cascade(value = { CascadeType.ALL })
@Where(clause = "cause_type = 'CA'")
@Fetch(value = org.hibernate.annotations.FetchMode.SUBSELECT)
// it is pretty lame that this is necessary
public List<CourseAgentAttribution> getCourseAgentAttributions() {
    if (courseAgentAttributions == null)
        courseAgentAttributions = new ArrayList<CourseAgentAttribution>();
    return courseAgentAttributions;
}

From source file:gov.nih.nci.cabig.caaers.domain.AdverseEvent.java

License:BSD License

/**
 * Gets the concomitant medication attributions.
 *
 * @return the concomitant medication attributions
 *//* ww  w .  j  av  a2s .  c  o m*/
@OneToMany(orphanRemoval = true)
@JoinColumn(name = "adverse_event_id", nullable = false)
@IndexColumn(name = "list_index")
@Cascade(value = { CascadeType.ALL })
@Where(clause = "cause_type = 'CM'")
@Fetch(value = org.hibernate.annotations.FetchMode.SUBSELECT)
// it is pretty lame that this is necessary
public List<ConcomitantMedicationAttribution> getConcomitantMedicationAttributions() {
    if (concomitantMedicationAttributions == null) {
        concomitantMedicationAttributions = new ArrayList<ConcomitantMedicationAttribution>();
    }
    return concomitantMedicationAttributions;
}

From source file:gov.nih.nci.cabig.caaers.domain.AdverseEvent.java

License:BSD License

/**
 * Gets the other cause attributions./* w ww.ja  v a2 s . c om*/
 *
 * @return the other cause attributions
 */
@OneToMany(orphanRemoval = true)
@JoinColumn(name = "adverse_event_id", nullable = false)
@IndexColumn(name = "list_index")
@Cascade(value = { CascadeType.ALL })
@Where(clause = "cause_type = 'OC'")
@Fetch(value = org.hibernate.annotations.FetchMode.SUBSELECT)
// it is pretty lame that this is necessary
public List<OtherCauseAttribution> getOtherCauseAttributions() {
    if (otherCauseAttributions == null) {
        otherCauseAttributions = new ArrayList<OtherCauseAttribution>();
    }
    return otherCauseAttributions;
}

From source file:gov.nih.nci.cabig.caaers.domain.AdverseEvent.java

License:BSD License

/**
 * Gets the disease attributions./* ww  w. jav  a  2  s .  c  o m*/
 *
 * @return the disease attributions
 */
@OneToMany(orphanRemoval = true)
@JoinColumn(name = "adverse_event_id", nullable = false)
@IndexColumn(name = "list_index")
@Cascade(value = { CascadeType.ALL })
@Where(clause = "cause_type = 'DH'")
@Fetch(value = org.hibernate.annotations.FetchMode.SUBSELECT)
// it is pretty lame that this is necessary
public List<DiseaseAttribution> getDiseaseAttributions() {
    if (diseaseAttributions == null) {
        diseaseAttributions = new ArrayList<DiseaseAttribution>();
    }
    return diseaseAttributions;
}

From source file:gov.nih.nci.cabig.caaers.domain.AdverseEvent.java

License:BSD License

/**
 * Gets the surgery attributions.// w ww.jav  a2s .  c o  m
 *
 * @return the surgery attributions
 */
@OneToMany(orphanRemoval = true)
@JoinColumn(name = "adverse_event_id", nullable = false)
@IndexColumn(name = "list_index")
@Cascade(value = { CascadeType.ALL })
@Where(clause = "cause_type = 'SI'")
@Fetch(value = org.hibernate.annotations.FetchMode.SUBSELECT)
// it is pretty lame that this is necessary
public List<SurgeryAttribution> getSurgeryAttributions() {
    if (surgeryAttributions == null) {
        surgeryAttributions = new ArrayList<SurgeryAttribution>();
    }
    return surgeryAttributions;
}

From source file:gov.nih.nci.cabig.caaers.domain.AdverseEvent.java

License:BSD License

/**
 * Gets the radiation attributions./*from  www. j  ava 2s  .  co m*/
 *
 * @return the radiation attributions
 */
@OneToMany(orphanRemoval = true)
@JoinColumn(name = "adverse_event_id", nullable = false)
@IndexColumn(name = "list_index")
@Cascade(value = { CascadeType.ALL })
@Where(clause = "cause_type = 'RI'")
@Fetch(value = org.hibernate.annotations.FetchMode.SUBSELECT)
// it is pretty lame that this is necessary
public List<RadiationAttribution> getRadiationAttributions() {
    if (radiationAttributions == null) {
        radiationAttributions = new ArrayList<RadiationAttribution>();
    }
    return radiationAttributions;
}

From source file:gov.nih.nci.cabig.caaers.domain.AdverseEvent.java

License:BSD License

/**
 * Gets the device attributions.//from  ww  w . j  av  a2s  . c  o  m
 *
 * @return the device attributions
 */
@OneToMany(orphanRemoval = true)
@JoinColumn(name = "adverse_event_id", nullable = false)
@IndexColumn(name = "list_index")
@Cascade(value = { CascadeType.ALL })
@Where(clause = "cause_type = 'DV'")
@Fetch(value = org.hibernate.annotations.FetchMode.SUBSELECT)
// it is pretty lame that this is necessary
public List<DeviceAttribution> getDeviceAttributions() {
    if (deviceAttributions == null) {
        deviceAttributions = new ArrayList<DeviceAttribution>();
    }
    return deviceAttributions;
}

From source file:gov.nih.nci.cabig.caaers.domain.AdverseEvent.java

License:BSD License

@OneToMany(orphanRemoval = true)
@JoinColumn(name = "adverse_event_id", nullable = false)
@IndexColumn(name = "list_index")
@Cascade(value = { CascadeType.ALL })
@Where(clause = "cause_type = 'OI'")
@Fetch(value = org.hibernate.annotations.FetchMode.SUBSELECT)
// it is pretty lame that this is necessary
public List<OtherInterventionAttribution> getOtherInterventionAttributions() {
    if (otherInterventionAttributions == null) {
        otherInterventionAttributions = new ArrayList<OtherInterventionAttribution>();
    }/*from  ww w  .jav  a  2 s .  c o  m*/
    return otherInterventionAttributions;
}

From source file:gov.nih.nci.cabig.caaers.domain.AdverseEvent.java

License:BSD License

@OneToMany(orphanRemoval = true)
@JoinColumn(name = "adverse_event_id", nullable = false)
@IndexColumn(name = "list_index")
@Cascade(value = { CascadeType.ALL })
@Where(clause = "cause_type = 'BI'")
@Fetch(value = org.hibernate.annotations.FetchMode.SUBSELECT)
// it is pretty lame that this is necessary
public List<BiologicalInterventionAttribution> getBiologicalInterventionAttributions() {
    if (biologicalInterventionAttributions == null) {
        biologicalInterventionAttributions = new ArrayList<BiologicalInterventionAttribution>();
    }/*from  ww w  .  j av a  2  s. c o  m*/
    return biologicalInterventionAttributions;
}