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:edu.duke.cabig.c3pr.domain.BaseResearchStaffDataContainer.java

License:BSD License

@ManyToMany
@Cascade(value = { CascadeType.ALL })
@JoinTable(name = "rs_hc_site_assocn", joinColumns = @JoinColumn(name = "rs_id"), inverseJoinColumns = @JoinColumn(name = "hcs_id"))
public List<BaseOrganizationDataContainer> getBaseOrganizationDataContainers() {
    return baseOrganizationDataContainers;
}

From source file:edu.duke.cabig.c3pr.domain.BookRandomization.java

License:BSD License

/**
 * Gets the book randomization entry internal.
 * //  www  . j ava  2s. c  om
 * @return the book randomization entry internal
 */
@OneToMany(fetch = FetchType.LAZY, orphanRemoval = true)
@JoinColumn(name = "rndm_id", nullable = false)
@Cascade(value = { CascadeType.ALL })
@OrderBy("stratumGroup, position")
public List<BookRandomizationEntry> getBookRandomizationEntryInternal() {
    return lazyListHelper.getInternalList(BookRandomizationEntry.class);
}

From source file:edu.duke.cabig.c3pr.domain.CompanionStudyAssociation.java

License:BSD License

@OneToMany(orphanRemoval = true)
@Cascade({ CascadeType.ALL })
@JoinColumn(name = "comp_assoc_id")
public List<StudySite> getStudySites() {
    return studySites;
}

From source file:edu.duke.cabig.c3pr.domain.Consent.java

License:BSD License

@OneToMany(orphanRemoval = true)
@JoinColumn(name = "con_id", nullable = false)
@Cascade(value = { CascadeType.ALL })
@Where(clause = "retired_indicator  = 'false'")
@OrderBy("id")//from w  ww. j av a  2  s  .c  o m
public List<ConsentQuestion> getQuestionsInternal() {
    return lazyListHelper.getInternalList(ConsentQuestion.class);
}

From source file:edu.duke.cabig.c3pr.domain.ContactMechanism.java

License:BSD License

@OneToMany(orphanRemoval = true)
@Fetch(FetchMode.SUBSELECT)/*from  w  w w .  jav  a  2 s. c o  m*/
@Cascade(value = { CascadeType.ALL })
@JoinColumn(name = "cntct_id")
@OrderBy("id")
public Set<ContactMechanismUseAssociation> getContactMechanismUseAssociation() {
    return contactMechanismUseAssociation;
}

From source file:edu.duke.cabig.c3pr.domain.ContactMechanismBasedRecipient.java

License:BSD License

/**
 * Gets the contact mechanisms internal.
 * /*from w  w w  .  j a  v  a  2s.c om*/
 * @return the contact mechanisms internal
 */
@OneToMany(fetch = FetchType.LAZY, orphanRemoval = true)
@Cascade(value = { CascadeType.ALL })
@JoinColumn(name = "recipients_id")
@Where(clause = "retired_indicator  = 'false'")
public List<ContactMechanism> getContactMechanismsInternal() {
    return lazyListHelper.getInternalList(ContactMechanism.class);
}

From source file:edu.duke.cabig.c3pr.domain.customfield.CustomFieldDefinition.java

License:BSD License

@OneToMany(mappedBy = "customFieldDefinition", fetch = FetchType.LAZY, orphanRemoval = true)
@Cascade(value = { CascadeType.ALL })
public List<CustomFieldPermissibleValue> getCustomFieldPermissibleValuesInternal() {
    return lazyListHelper.getInternalList(CustomFieldPermissibleValue.class);
}

From source file:edu.duke.cabig.c3pr.domain.customfield.CustomFieldDefinition.java

License:BSD License

@OneToMany(mappedBy = "customFieldDefinition", fetch = FetchType.LAZY, orphanRemoval = true)
@Cascade(value = { CascadeType.ALL })
public List<CustomField> getCustomFieldsInternal() {
    return lazyListHelper.getInternalList(CustomField.class);
}

From source file:edu.duke.cabig.c3pr.domain.EndPoint.java

License:BSD License

/**
 * Gets the errors.//from   w ww  . j a  va2s. c  o  m
 * 
 * @return the errors
 */
@OneToMany(fetch = FetchType.EAGER, orphanRemoval = true)
@Cascade(value = { CascadeType.ALL })
@JoinColumn(name = "endpoint_id", nullable = false)
public List<Error> getErrors() {
    return errors;
}

From source file:edu.duke.cabig.c3pr.domain.Epoch.java

License:BSD License

/**
 * Gets the arms internal./*  w  w w  .  ja  va  2 s  .c o m*/
 *
 * @return the arms internal
 */
@OneToMany(fetch = FetchType.LAZY, orphanRemoval = true)
@Cascade(value = { CascadeType.ALL })
@JoinColumn(name = "eph_id")
@Where(clause = "retired_indicator  = 'false'")
public List<Arm> getArmsInternal() {
    return lazyListHelper.getInternalList(Arm.class);
}