Example usage for javax.persistence FetchType LAZY

List of usage examples for javax.persistence FetchType LAZY

Introduction

In this page you can find the example usage for javax.persistence FetchType LAZY.

Prototype

FetchType LAZY

To view the source code for javax.persistence FetchType LAZY.

Click Source Link

Document

Defines that data can be lazily fetched.

Usage

From source file:com.jeefuse.system.security.model.GsysRole.java

/**
 * ------------------------------------------------------------------------
 * gsysRelRoleFunctions//from  ww w.j av  a 2 s. c o m
 * ------------------------------------------------------------------------
 * @generated
 */
@OneToMany(fetch = FetchType.LAZY, mappedBy = "gsysRole", cascade = CascadeType.REMOVE)
public List<GsysRelRoleFunction> getGsysRelRoleFunctions() {
    if (this.gsysRelRoleFunctions == null) {
        this.gsysRelRoleFunctions = new ArrayList<GsysRelRoleFunction>();
    }
    return gsysRelRoleFunctions;
}

From source file:org.dspace.orm.entity.Item.java

@ManyToMany(fetch = FetchType.LAZY, cascade = CascadeType.DETACH)
@JoinTable(name = "item2bundle", joinColumns = {
        @JoinColumn(name = "item_id", nullable = false) }, inverseJoinColumns = {
                @JoinColumn(name = "bundle_id", nullable = false) })
public List<Bundle> getBundles() {
    return bundles;
}

From source file:org.dspace.orm.entity.Collection.java

@ManyToOne(fetch = FetchType.LAZY)
@JoinColumn(name = "template_item_id", nullable = true)
public Item getTemplateItem() {
    return templateItem;
}

From source file:com.testing26thjuly_.db123testing.SelfRelationTable.java

@JsonIgnoreProperties({ "selfRelationTableByIntCol", "selfRelationTablesForIntCol" })
@OneToMany(fetch = FetchType.LAZY, cascade = CascadeType.ALL, mappedBy = "selfRelationTableByIntCol")
public List<SelfRelationTable> getSelfRelationTablesForIntCol() {
    return this.selfRelationTablesForIntCol;
}

From source file:com.sccl.attech.modules.sys.entity.Area.java

@OneToMany(mappedBy = "parent", fetch = FetchType.LAZY)
@Where(clause = "del_flag='" + DEL_FLAG_NORMAL + "'")
@OrderBy(value = "code")
@Fetch(FetchMode.SUBSELECT)//from  w  w w . j a  v a  2  s .c o m
@NotFound(action = NotFoundAction.IGNORE)
@JsonIgnore
@Cache(usage = CacheConcurrencyStrategy.READ_WRITE)
public List<Area> getChildList() {
    return childList;
}

From source file:edu.ku.brc.specify.datamodel.CollectionRelationship.java

/**
 * // ww  w . j  a  va 2s  . co  m
 */
@ManyToOne(cascade = {}, fetch = FetchType.LAZY)
@JoinColumn(name = "LeftSideCollectionID", unique = false, nullable = false, insertable = true, updatable = true)
public CollectionObject getLeftSide() {
    return this.leftSide;
}

From source file:com.ravipatel.statusserver.models.User.java

@JsonIgnore
@OneToMany(fetch = FetchType.LAZY, mappedBy = "user")
public Set<UserState> getUserStates() {
    return this.userStates;
}

From source file:com.marand.thinkmed.medications.model.impl.MedicationVersionImpl.java

@Override
@ManyToOne(targetEntity = MedicationGenericImpl.class, fetch = FetchType.LAZY)
public MedicationGeneric getMedicationGeneric() {
    return medicationGeneric;
}

From source file:net.groupbuy.entity.Receiver.java

/**
 * ?
 * 
 * @return 
 */
@NotNull
@ManyToOne(fetch = FetchType.LAZY)
public Area getArea() {
    return area;
}

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

/**
 * Gets the stratification criterion answer combination internal.
 * //from  ww  w  .j a  va2 s.  c  o m
 * @return the stratification criterion answer combination internal
 */
@OneToMany(fetch = FetchType.LAZY, orphanRemoval = true)
@Cascade(value = { CascadeType.ALL })
@JoinColumn(name = "STR_GRP_ID")
public List<StratificationCriterionAnswerCombination> getStratificationCriterionAnswerCombinationInternal() {
    return lazyListHelper.getInternalList(StratificationCriterionAnswerCombination.class);
}