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:uk.nhs.cfh.dsp.snomed.expression.model.impl.AbstractExpressionImpl.java

@OneToMany(cascade = CascadeType.ALL, fetch = FetchType.LAZY, targetEntity = AbstractExpressionImpl.class)
@JoinTable(name = "EQUIVALENT_EXPRESSIONS", joinColumns = @JoinColumn(name = "uuid"), inverseJoinColumns = @JoinColumn(name = "equivalent_expression_id"))
public Collection<Expression> getEquivalentExpressions() {
    return equivalentExpressions;
}

From source file:ch.systemsx.cisd.openbis.generic.shared.dto.PersonPE.java

@OneToMany(fetch = FetchType.LAZY, mappedBy = "personInternal", cascade = CascadeType.ALL)
private final Set<RoleAssignmentPE> getRoleAssignmentsInternal() {
    return roleAssignments;
}

From source file:uk.nhs.cfh.dsp.snomed.expression.model.impl.AbstractExpressionWithFocusConcepts.java

/**
 * Gets the role groups./*from  www .  j  a v a  2s .  co  m*/
 *
 * @return the role groups
 */
@OneToMany(cascade = CascadeType.ALL, fetch = FetchType.LAZY, targetEntity = SnomedRoleGroupImpl.class)
@JoinTable(name = "EFC_ROLEGROUPS", joinColumns = @JoinColumn(name = "uuid"), inverseJoinColumns = @JoinColumn(name = "rolegroup_id"))
public Collection<SnomedRoleGroup> getRoleGroups() {
    return roleGroups;
}

From source file:gov.nih.nci.firebird.data.Organization.java

/**
 * Returns the map of roles for this organization.
 *
 * @return the roles.// www  . j  a v a 2 s  .c  o  m
 */
@OneToMany(mappedBy = "organization", cascade = CascadeType.ALL, fetch = FetchType.EAGER)
@MapKey(name = "roleType")
public Map<OrganizationRoleType, AbstractOrganizationRole> getRoles() {
    return roles;
}

From source file:com.infinities.keystone4j.model.assignment.Role.java

@JsonView(Views.All.class)
@OneToMany(fetch = FetchType.LAZY, mappedBy = "role", cascade = CascadeType.ALL)
public Set<RoleAssignment> getRoleAssignments() {
    return roleAssignments;
}

From source file:com.infinities.keystone4j.model.assignment.Project.java

@JsonView(Views.All.class)
@OneToMany(fetch = FetchType.LAZY, mappedBy = "defaultProject", cascade = CascadeType.ALL)
public Set<User> getUsers() {
    return users;
}

From source file:uk.nhs.cfh.dsp.srth.information.model.impl.om.ehr.EHRImpl.java

/**
 * Gets the clinical findings.//from  w  ww  .j  a  v a2s  .com
 *
 * @return the clinical findings
 */
@OneToMany(cascade = CascadeType.ALL, fetch = FetchType.EAGER, targetEntity = ClinicalFindingEntry.class)
@JoinTable(name = "EHR_FINDINGS", joinColumns = @JoinColumn(name = PATIENT_ID), inverseJoinColumns = @JoinColumn(name = "finding_id"))
@ForeignKey(name = "FK_EHR_FIN", inverseName = "FK_FIN_EHR")
public Set<BoundClinicalEntry> getClinicalFindings() {
    return findings;
}

From source file:uk.nhs.cfh.dsp.snomed.objectmodel.impl.SnomedConceptImpl.java

@ManyToMany(cascade = CascadeType.ALL, fetch = FetchType.LAZY, targetEntity = SnomedRelationshipImpl.class)
@JoinTable(name = "CONCEPT_RELATIONSHIPS", joinColumns = @JoinColumn(name = "concept_id"), inverseJoinColumns = @JoinColumn(name = "relationships_id"))
public Collection<SnomedRelationship> getRelationships() {
    return relationships;
}

From source file:com.hmsinc.epicenter.model.surveillance.Anomaly.java

/**
 * @return the classification/*w  ww.  ja va 2  s.  co m*/
 */
@ManyToOne(cascade = { CascadeType.ALL }, fetch = FetchType.LAZY)
@JoinColumn(name = "ID_CLASSIFICATION", unique = false, nullable = false, insertable = true, updatable = true)
@org.hibernate.annotations.ForeignKey(name = "FK_ANOMALY_3")
public Classification getClassification() {
    return classification;
}

From source file:org.eclipse.jubula.client.core.model.ProjectPO.java

/**
 *      /*  ww  w  .j ava  2 s.c  o m*/
 * @return Returns the specObjCont.
 */
@OneToOne(cascade = CascadeType.ALL, fetch = FetchType.LAZY)
@JoinColumn(name = "SPECOBJ_CONT", unique = true)
private SpecObjContPO getHbmSpecObjCont() {
    return m_specObjCont;
}