本文整理汇总了Java中org.hibernate.annotations.FetchMode.SELECT属性的典型用法代码示例。如果您正苦于以下问题:Java FetchMode.SELECT属性的具体用法?Java FetchMode.SELECT怎么用?Java FetchMode.SELECT使用的例子?那么, 这里精选的属性代码示例或许可以为您提供帮助。您也可以进一步了解该属性所在类org.hibernate.annotations.FetchMode
的用法示例。
在下文中一共展示了FetchMode.SELECT属性的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的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;
}
示例2: getStrings
@OneToMany(cascade = CascadeType.ALL, mappedBy = "bundle")
@Fetch(value = FetchMode.SELECT)
@MapKey(name = "locale")
public Map<String, LanguageString> getStrings()
{
return strings;
}
示例3: getAlternateNames
/**
* @return A list of the {@link AlternateName}s for this street
*/
@OneToMany(cascade = { CascadeType.ALL }, mappedBy = "street")
@Cache(usage = CacheConcurrencyStrategy.NONSTRICT_READ_WRITE)
@Fetch(FetchMode.SELECT)
public List<AlternateOsmName> getAlternateNames() {
return alternateNames;
}
示例4: getHouseNumbers
/**
* @return the houseNumbers associated to that street
*/
@OneToMany(cascade = { CascadeType.ALL }, mappedBy = "street")
@Cache(usage = CacheConcurrencyStrategy.NONSTRICT_READ_WRITE)
@Fetch(FetchMode.SELECT)
@Sort(comparator=HouseNumberComparator.class,type=SortType.COMPARATOR)
public SortedSet<HouseNumber> getHouseNumbers() {
return houseNumbers;
}
示例5: getAlternateNames
/**
* @return A list of the {@link AlternateName}s for this GisFeature
*/
@OneToMany(cascade = { CascadeType.ALL }, mappedBy = "gisFeature")
@Cache(usage = CacheConcurrencyStrategy.NONSTRICT_READ_WRITE)
@Fetch(FetchMode.SELECT)
public Set<AlternateName> getAlternateNames() {
return alternateNames;
}
示例6: getTestRun
@Override
@ManyToOne(fetch = FetchType.EAGER, optional = false)
@Fetch(FetchMode.SELECT)
@ForeignKey(name = "FK_TESTRUN")
@Index(name = "IDX_TESTRUNS")
public TestRun getTestRun() {
return (TestRun) super.getTestRun();
}
示例7: getCriterionVOs
/**
* @return the criterionVOs
@Sort(type=SortType.COMPARATOR,comparator=CriterionComparator.class)
*/
@JazzProp(name="Critérios",renderer=JazzRenderer.GRID)
@OneToMany(cascade=CascadeType.ALL, fetch=FetchType.EAGER, orphanRemoval=true)//atribui o orphan removal aa colecao de criterios. 20h 170611. os criterios tem de ser apagados
@JoinColumn(name="fk_question")
@Fetch(FetchMode.SELECT)
@Valid
public Set<AbstractCriterionVO> getCriterionVOs() {
return criterionVOs;
}
示例8: getStatus
@Override
@ManyToOne(fetch = FetchType.EAGER, optional = false)
@Fetch(FetchMode.SELECT)
@ForeignKey(name = "FK_RUNSTATUS")
@Index(name = "IDX_RUNSTATUS")
public RunStatus getStatus() {
return (RunStatus) super.getStatus();
}
示例9: getQuestions
@JazzProp(name="Questões",renderer=JazzRenderer.SUBMODULE,listable=false, searchable=false)
@ManyToMany(cascade=CascadeType.ALL,fetch=FetchType.EAGER)
@Size(min=1, message="Adicione pelo menos uma questão!")
@NotEmpty(message="Adicione pelo menos uma questão!")
@Valid()
@Fetch(FetchMode.SELECT)//coloquei este fetch pq o hibernate vai multiplicar os resultados, por nao se tratar de um set. Estúpido!
@OrderBy("ordem")
public List<QuestionVO> getQuestions() {
return questions;
}
示例10: getAttachments
@Override
@SuppressWarnings("unchecked")
@ManyToMany(fetch = FetchType.EAGER)
@JoinTable(name = "CUB_TESTCASES_ATTACHMENTS")
@Fetch(FetchMode.SELECT)
public List<CaseAttachment> getAttachments() {
return super.getAttachments();
}
示例11: getResults
@Override
@SuppressWarnings("unchecked")
@OneToMany(mappedBy = "testRun", cascade = CascadeType.ALL, fetch = FetchType.LAZY)
@Fetch(FetchMode.SELECT)
// Setting this FetchMode to JOIN will duplicate rows when querying for TestRun.
public List<TestRunResult> getResults() {
return super.getResults();
}
示例12: getExamOMRMetadataVO
/**
* @return the examOMRMetadataVO
*/
@OneToMany(cascade = CascadeType.ALL, orphanRemoval = true, fetch=FetchType.EAGER)
@JoinColumn(name = "fk_exam")
@MapKey(name = "omrKey")
@JazzProp(name="",ignore=true)
@Fetch(FetchMode.SELECT)
public Map<String, ExamOMRMetadataVO> getExamOMRMetadataVO() {
return examOMRMetadataVO;
}
示例13: getProduct
@Override
@ManyToOne(fetch = FetchType.EAGER, optional = false)
@Fetch(FetchMode.SELECT)
@ForeignKey(name = "FK_BUILDS_PRODUCTS")
@Index(name = "IDX_BUILDS_PRODUCTS")
public Product getProduct() {
return (Product) super.getProduct();
}
示例14: getTestPlan
@Override
@ManyToOne(fetch = FetchType.EAGER, optional = false)
@Fetch(FetchMode.SELECT)
@ForeignKey(name = "FK_TESTCASES_TESTPLAN")
@Index(name = "IDX_TESTCASES_TESTPLAN")
public TestPlan getTestPlan() {
return (TestPlan) super.getTestPlan();
}
示例15: getQuestionnaires
/**
* @return the questionnaires
*/
@JazzProp(name = "Questionários",searchable=false,listable=false)
@ManyToMany(cascade = CascadeType.DETACH, fetch=FetchType.EAGER)
@NotEmpty(message="Um exame deve possuir ao menos um questionário selecionado!")
@Fetch(FetchMode.SELECT)
public List<QuestionnaireVO> getQuestionnaires() {
return questionnaires;
}