当前位置: 首页>>代码示例>>Java>>正文


Java FetchType.EAGER属性代码示例

本文整理汇总了Java中javax.persistence.FetchType.EAGER属性的典型用法代码示例。如果您正苦于以下问题:Java FetchType.EAGER属性的具体用法?Java FetchType.EAGER怎么用?Java FetchType.EAGER使用的例子?那么, 这里精选的属性代码示例或许可以为您提供帮助。您也可以进一步了解该属性所在javax.persistence.FetchType的用法示例。


在下文中一共展示了FetchType.EAGER属性的14个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: getPlanServices

@OneToMany(cascade = CascadeType.ALL, fetch = FetchType.EAGER, orphanRemoval = true)
@JoinColumn(name = "user_id", insertable = false, nullable = false, updatable = false)
// MOSCOW
@Fetch(FetchMode.SELECT)
// Это отсечение дублирования при джойне таблици, т.к. в QPlanService есть @OneToOne к QService, и в нем есть @OneToMany к QServiceLang - дублится по
// количеству переводов
// This is the truncation of the duplication when the table joins, since In QPlanService there is @OneToOne to QService, and there is @OneToMany to
// QServiceLang - it is duplicated by the number of translations.
public List<QPlanService> getPlanServices() {
    return planServices;
}
 
开发者ID:bcgov,项目名称:sbc-qsystem,代码行数:11,代码来源:QUser.java

示例2: getFetchMode

public static FetchMode getFetchMode(FetchType fetch) {
	if ( fetch == FetchType.EAGER ) {
		return FetchMode.JOIN;
	}
	else {
		return FetchMode.SELECT;
	}
}
 
开发者ID:lamsfoundation,项目名称:lams,代码行数:8,代码来源:AnnotationBinder.java

示例3: getGoods8JPASet

@OneToMany(targetEntity = Goods8JPA.class, cascade = CascadeType.ALL,
          fetch = FetchType.EAGER)
@JoinColumn(name = "join_user_goodsSet", foreignKey =
@ForeignKey(name = "join_fk_user_goodsSet"))
@JoinTable(name = "jpa_user_goodsSet_table", foreignKey =
@ForeignKey(name = "table_user_goodsSet"))
public Set<Goods8JPA> getGoods8JPASet()
{
    return goods8JPASet;
}
 
开发者ID:SessionFactory,项目名称:tinyshop8,代码行数:10,代码来源:User8JPA.java

示例4: getCode

/**
 * @return code
 */
@OneToOne(fetch = FetchType.EAGER, cascade = CascadeType.ALL)
@JoinColumn(name = "idCode")
public AccessCodeEntity getCode() {

  return this.code;
}
 
开发者ID:oasp,项目名称:oasp-tutorial-sources,代码行数:9,代码来源:VisitorEntity.java

示例5: getEmployees

@OneToMany(cascade=CascadeType.ALL, fetch=FetchType.EAGER, mappedBy="company")
public Set<Employee> getEmployees() {
    return this.employees;
}
 
开发者ID:amritbhat786,项目名称:DocIT,代码行数:4,代码来源:Company.java

示例6: getUser

@ManyToOne(fetch=FetchType.EAGER, optional=false)
public User getUser() {return user;}
 
开发者ID:awslabs,项目名称:aws-photosharing-example,代码行数:2,代码来源:Share.java

示例7: getSharedWith

@ManyToOne(fetch=FetchType.EAGER, optional=true)
public User getSharedWith() {return sharedWith;}
 
开发者ID:awslabs,项目名称:aws-photosharing-example,代码行数:2,代码来源:Share.java

示例8: getFuncionario

@ManyToOne(fetch = FetchType.EAGER)
public Funcionario getFuncionario() {
	return funcionario;
}
 
开发者ID:m4rciosouza,项目名称:ponto-inteligente-api,代码行数:4,代码来源:Lancamento.java

示例9: getEmpresa

@ManyToOne(fetch = FetchType.EAGER)
public Empresa getEmpresa() {
	return empresa;
}
 
开发者ID:m4rciosouza,项目名称:ponto-inteligente-api,代码行数:4,代码来源:Funcionario.java

示例10: getUser

@ManyToOne(fetch = FetchType.EAGER)
@JoinColumn(name = "userId", nullable = false)
public UserModel getUser() {
	return user;
}
 
开发者ID:imaTowan,项目名称:Towan,代码行数:5,代码来源:UserRoleModel.java

示例11: getOffice

@ManyToOne(fetch = FetchType.EAGER)
@JoinColumn(name = "office_id")
public QOffice getOffice() {
    return office;
}
 
开发者ID:bcgov,项目名称:sbc-qsystem,代码行数:5,代码来源:QUser.java

示例12: getPessoa

@ManyToOne(fetch = FetchType.EAGER)
public Pessoa getPessoa() {
	return pessoa;
}
 
开发者ID:SergioColetto,项目名称:borabeber-api,代码行数:4,代码来源:Estabelecimento.java

示例13: getEstabelecimento

@ManyToOne(fetch = FetchType.EAGER)
public Estabelecimento getEstabelecimento() {
	return estabelecimento;
}
 
开发者ID:SergioColetto,项目名称:borabeber-api,代码行数:4,代码来源:Promocao.java

示例14:

@ManyToOne(targetEntity = User8JPA.class, cascade = CascadeType.ALL,
              fetch = FetchType.EAGER)
    @JoinColumn(name = "join_m2o_goods_user", foreignKey =
    @ForeignKey(name = "fk_join_m2o_goods_user"))
    public User8JPA getUser8JPA()
    {
        return user8JPA;
    } 
开发者ID:SessionFactory,项目名称:tinyshop8,代码行数:8,代码来源:Goods8JPA.java


注:本文中的javax.persistence.FetchType.EAGER属性示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。