本文整理汇总了Java中org.hibernate.annotations.ForeignKey类的典型用法代码示例。如果您正苦于以下问题:Java ForeignKey类的具体用法?Java ForeignKey怎么用?Java ForeignKey使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
ForeignKey类属于org.hibernate.annotations包,在下文中一共展示了ForeignKey类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: getOwner
import org.hibernate.annotations.ForeignKey; //导入依赖的package包/类
@ForeignKey(name = "fk_assignment_reference")
@MapsId("owner")
@ManyToOne(fetch = FetchType.LAZY)
@NotQueryable
public RAssignment getOwner() {
return owner;
}
示例2: getIncludeRef
import org.hibernate.annotations.ForeignKey; //导入依赖的package包/类
@Where(clause = RObjectReference.REFERENCE_TYPE + "= 7")
@OneToMany(mappedBy = RObjectReference.F_OWNER, orphanRemoval = true)
@ForeignKey(name = "none")
@Cascade({org.hibernate.annotations.CascadeType.ALL})
public Set<RObjectReference<RObjectTemplate>> getIncludeRef() {
if (includeRef == null) {
includeRef = new HashSet<>();
}
return includeRef;
}
示例3: getOwner
import org.hibernate.annotations.ForeignKey; //导入依赖的package包/类
@Id
@ForeignKey(name = "fk_trigger_owner")
@MapsId("owner")
@ManyToOne(fetch = FetchType.LAZY)
@NotQueryable
public RObject getOwner() {
return owner;
}
示例4: getRelacionsOrigen
import org.hibernate.annotations.ForeignKey; //导入依赖的package包/类
@ManyToMany()
@JoinTable(
name="hel_expedient_rels",
[email protected](name="origen_id", referencedColumnName="id"),
[email protected](name="desti_id", referencedColumnName="id")
)
@ForeignKey(name="hel_origen_exprel_fk", inverseName="hel_desti_exprel_fk")
public Set<ExpedientHelium> getRelacionsOrigen() {
return this.relacionsOrigen;
}
示例5: getRelacionsOrigen
import org.hibernate.annotations.ForeignKey; //导入依赖的package包/类
@ManyToMany()
@JoinTable(
name="hel_expedient_rels",
[email protected](name="origen_id", referencedColumnName="id"),
[email protected](name="desti_id", referencedColumnName="id")
)
@ForeignKey(name="hel_origen_exprel_fk", inverseName="hel_desti_exprel_fk")
public Set<Expedient> getRelacionsOrigen() {
return this.relacionsOrigen;
}
示例6: getPermisos
import org.hibernate.annotations.ForeignKey; //导入依赖的package包/类
@ManyToMany(fetch=FetchType.EAGER)
@JoinTable(
name="hel_usuari_permis",
joinColumns=
@JoinColumn(name="codi", referencedColumnName="codi"),
inverseJoinColumns=
@JoinColumn(name="permis", referencedColumnName="codi")
)
@ForeignKey(name="hel_permis_usuari_fk", inverseName="hel_usuari_permis_fk")
public Set<Permis> getPermisos() {
return this.permisos;
}
示例7: getServiceType
import org.hibernate.annotations.ForeignKey; //导入依赖的package包/类
@ElementCollection
@ForeignKey(name = "fk_service_type")
@CollectionTable(name = "m_service_type", joinColumns = {
@JoinColumn(name = "service_oid", referencedColumnName = "oid")
})
@Cascade({org.hibernate.annotations.CascadeType.ALL})
public Set<String> getServiceType() {
return serviceType;
}
示例8: getOrgType
import org.hibernate.annotations.ForeignKey; //导入依赖的package包/类
@ElementCollection
@ForeignKey(name = "fk_org_org_type")
@CollectionTable(name = "m_org_org_type", joinColumns = {
@JoinColumn(name = "org_oid", referencedColumnName = "oid")
})
@Cascade({org.hibernate.annotations.CascadeType.ALL})
public Set<String> getOrgType() {
return orgType;
}
示例9: getTarget
import org.hibernate.annotations.ForeignKey; //导入依赖的package包/类
@ForeignKey(name="none")
@ManyToOne(fetch = FetchType.LAZY, optional = true)
@JoinColumn(referencedColumnName = "oid", updatable = false, insertable = false, nullable = true)
@NotFound(action = NotFoundAction.IGNORE)
@NotQueryable
// only for HQL use
public RObject getTarget() {
return null;
}
示例10: getExclusion
import org.hibernate.annotations.ForeignKey; //导入依赖的package包/类
@OneToMany(mappedBy = "owner", orphanRemoval = true)
@ForeignKey(name = "none")
@Cascade({org.hibernate.annotations.CascadeType.ALL})
public Set<RExclusion> getExclusion() {
if (exclusion == null) {
exclusion = new HashSet<>();
}
return exclusion;
}
示例11: getTarget
import org.hibernate.annotations.ForeignKey; //导入依赖的package包/类
@ForeignKey(name="none")
@ManyToOne(fetch = FetchType.LAZY, optional = true)
@JoinColumn(referencedColumnName = "oid", updatable = false, insertable = false, nullable = true)
@NotFound(action = NotFoundAction.IGNORE)
@NotQueryable
// declared for HQL use only
public RObject getTarget() {
return null;
}
示例12: chars
import org.hibernate.annotations.ForeignKey; //导入依赖的package包/类
@ForeignKey(name = "fk_acc_cert_wi_ref_owner") // max. 30 chars (Oracle)
@MapsId("workItem")
@ManyToOne(fetch = FetchType.LAZY)
@NotQueryable
public RAccessCertificationWorkItem getOwner() {
return owner;
}
示例13: getExpedientTipus
import org.hibernate.annotations.ForeignKey; //导入依赖的package包/类
@SuppressWarnings("deprecation")
@ManyToOne(optional=true)
@JoinColumn(name="expedient_tipus")
@ForeignKey(name="hel_exptipus_seqdefany_fk")
@Cascade({CascadeType.DELETE_ORPHAN})
public ExpedientTipus getExpedientTipus() {
return expedientTipus;
}
示例14: getDependent
import org.hibernate.annotations.ForeignKey; //导入依赖的package包/类
@ElementCollection
@ForeignKey(name = "fk_task_dependent")
@CollectionTable(name = "m_task_dependent", joinColumns = {
@JoinColumn(name = "task_oid", referencedColumnName = "oid")
})
@Cascade({org.hibernate.annotations.CascadeType.ALL})
public Set<String> getDependent() {
return dependent;
}
示例15: getRecord
import org.hibernate.annotations.ForeignKey; //导入依赖的package包/类
@ForeignKey(name = "none")
@MapsId("record")
@ManyToOne(fetch = FetchType.LAZY)
@JoinColumns({
@JoinColumn(name = COLUMN_RECORD_ID, referencedColumnName = "id")
})
public RAuditEventRecord getRecord() {
return record;
}