Example usage for javax.persistence CascadeType REMOVE

List of usage examples for javax.persistence CascadeType REMOVE

Introduction

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

Prototype

CascadeType REMOVE

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

Click Source Link

Document

Cascade remove operation

Usage

From source file:com.impetus.ankush.common.domain.Node.java

/**
 * @return the configuration//  w  ww . j ava 2  s.  co m
 */
@OneToMany(fetch = FetchType.LAZY, cascade = CascadeType.REMOVE)
@JoinColumns({ @JoinColumn(name = "clusterId", referencedColumnName = "clusterId"),
        @JoinColumn(name = "host", referencedColumnName = "publicIp") })
public List<Event> getEvents() {
    return events;
}

From source file:com.infinities.skyport.entity.Organization.java

@OneToMany(fetch = FetchType.LAZY, mappedBy = "organization", cascade = CascadeType.REMOVE)
public Set<User> getUsers() {
    return this.users;
}

From source file:com.cubeia.backoffice.users.entity.User.java

@Fetch(FetchMode.JOIN)
@OneToOne(fetch = FetchType.EAGER, cascade = { CascadeType.PERSIST, CascadeType.REMOVE, CascadeType.MERGE })
@JoinColumn(name = "information_fk", nullable = true)
public UserInformation getInformation() {
    return information;
}

From source file:com.infinities.skyport.entity.Role.java

@XmlTransient
@OneToMany(fetch = FetchType.LAZY, mappedBy = "role", cascade = CascadeType.REMOVE)
public Set<UserRole> getUserRoles() {
    return this.userRoles;
}

From source file:com.impetus.ankush.common.domain.Cluster.java

/**
 * @return the haServices/*from  w w w .jav a2  s.c o  m*/
 */
@OneToMany(mappedBy = CLUSTER_ID, fetch = FetchType.LAZY, cascade = CascadeType.REMOVE)
@JsonIgnore
public List<Service> getServices() {
    return services;
}

From source file:com.infinities.skyport.entity.PermissionOperation.java

@JsonSerialize(using = BasicSelfRecursiveSerializer.class)
@JsonView(Views.Full.class)
@XmlElement(name = "permission")
@OneToMany(fetch = FetchType.LAZY, mappedBy = "parent", cascade = CascadeType.REMOVE)
public Set<PermissionOperation> getPermissionOperations() {
    return permissionOperations;
}

From source file:com.dp2345.entity.Cart.java

/**
 * ?/*from   w ww  . j a v a 2 s  . c  om*/
 * 
 * @return 
 */
@OneToMany(mappedBy = "cart", fetch = FetchType.LAZY, cascade = CascadeType.REMOVE)
public Set<CartItem> getCartItems() {
    return cartItems;
}

From source file:com.hrdb.Department.java

@JsonInclude(Include.NON_EMPTY)
@OneToMany(fetch = FetchType.LAZY, cascade = CascadeType.REMOVE, mappedBy = "department")
public List<Employee> getEmployees() {
    return this.employees;
}

From source file:com.impetus.ankush.common.domain.Node.java

/**
 * @return the configuration//from w w  w  . j a  v a2  s . c  o m
 */
@OneToMany(fetch = FetchType.LAZY, cascade = CascadeType.REMOVE)
@JoinColumns({ @JoinColumn(name = "node", referencedColumnName = "publicIp") })
public List<Service> getServices() {
    return services;
}

From source file:com.infinities.skyport.entity.Organization.java

@OneToMany(fetch = FetchType.LAZY, mappedBy = "organization", cascade = CascadeType.REMOVE)
public Set<Role> getRoles() {
    return roles;
}