本文整理汇总了Java中org.hibernate.annotations.CacheConcurrencyStrategy.READ_WRITE属性的典型用法代码示例。如果您正苦于以下问题:Java CacheConcurrencyStrategy.READ_WRITE属性的具体用法?Java CacheConcurrencyStrategy.READ_WRITE怎么用?Java CacheConcurrencyStrategy.READ_WRITE使用的例子?那么, 这里精选的属性代码示例或许可以为您提供帮助。您也可以进一步了解该属性所在类org.hibernate.annotations.CacheConcurrencyStrategy
的用法示例。
在下文中一共展示了CacheConcurrencyStrategy.READ_WRITE属性的8个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: getBadges
@ManyToMany
@JoinTable(name = "user_badge", joinColumns = { @JoinColumn(name = "user_id") }, inverseJoinColumns = { @JoinColumn(name = "badge_id") })
@Fetch(FetchMode.SUBSELECT)
@OrderBy("id")
@Cache(usage = CacheConcurrencyStrategy.READ_WRITE)
public Set<Badge> getBadges() {
return badges;
}
示例2: getRoleList
@ManyToMany
//�м����,��������Ĭ����������
@JoinTable(name = "ACCT_USER_ROLE", joinColumns = { @JoinColumn(name = "USER_ID") }, inverseJoinColumns = { @JoinColumn(name = "ROLE_ID") })
//Fecth���Զ���
@Fetch(FetchMode.SUBSELECT)
//���ϰ�id����.
@OrderBy("id")
//�����ж���id�Ļ���.
@Cache(usage = CacheConcurrencyStrategy.READ_WRITE)
public List<AcctRole> getRoleList() {
return roleList;
}
示例3: getRoleList
@ManyToMany
@JoinTable(name = "ss_user_role", joinColumns = { @JoinColumn(name = "user_id") }, inverseJoinColumns = { @JoinColumn(name = "role_id") })
// Fecth策略定义
@Fetch(FetchMode.SUBSELECT)
// 集合按id排序
@OrderBy("id ASC")
// 缓存策略
@Cache(usage = CacheConcurrencyStrategy.READ_WRITE)
public List<Role> getRoleList() {
return roleList;
}
示例4: getLogin
@Cache(usage=CacheConcurrencyStrategy.READ_WRITE)
@ManyToOne(fetch = FetchType.LAZY)
@JoinColumn(name = "userId", nullable = false)
public Login getLogin() {
return this.login;
}
示例5: getRole
@Cache(usage=CacheConcurrencyStrategy.READ_WRITE)
@ManyToOne(fetch = FetchType.LAZY)
@JoinColumn(name = "roleId", nullable = false)
public Role getRole() {
return this.role;
}
示例6: getCustomerAccount
@Cache(usage=CacheConcurrencyStrategy.READ_WRITE)
@OneToOne(fetch = FetchType.LAZY)
@PrimaryKeyJoinColumn
public CustomerAccount getCustomerAccount() {
return this.customerAccount;
}
示例7: getRoles
@ManyToMany
@JoinTable(name = "users_roles")
@Cache(usage = CacheConcurrencyStrategy.READ_WRITE)
public Set<Role> getRoles() {
return roles;
}
示例8: getPermissions
@CollectionOfElements
@JoinTable(name = "roles_permissions")
@Cache(usage = CacheConcurrencyStrategy.READ_WRITE)
public Set<String> getPermissions() {
return permissions;
}