本文整理汇总了Java中org.kuali.rice.kim.document.IdentityManagementRoleDocument.setDelegations方法的典型用法代码示例。如果您正苦于以下问题:Java IdentityManagementRoleDocument.setDelegations方法的具体用法?Java IdentityManagementRoleDocument.setDelegations怎么用?Java IdentityManagementRoleDocument.setDelegations使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类org.kuali.rice.kim.document.IdentityManagementRoleDocument
的用法示例。
在下文中一共展示了IdentityManagementRoleDocument.setDelegations方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: loadRoleDoc
import org.kuali.rice.kim.document.IdentityManagementRoleDocument; //导入方法依赖的package包/类
@Override
public void loadRoleDoc(IdentityManagementRoleDocument identityManagementRoleDocument, Role role){
RoleBo roleBo = getDataObjectService().find(RoleBo.class, role.getId());
identityManagementRoleDocument.setRoleId(roleBo.getId());
identityManagementRoleDocument.setKimType(KimTypeBo.to(roleBo.getKimRoleType()));
identityManagementRoleDocument.setRoleTypeName(roleBo.getKimRoleType().getName());
identityManagementRoleDocument.setRoleTypeId(roleBo.getKimTypeId());
identityManagementRoleDocument.setRoleName(roleBo.getName());
identityManagementRoleDocument.setRoleDescription(roleBo.getDescription());
identityManagementRoleDocument.setActive(roleBo.isActive());
identityManagementRoleDocument.setRoleNamespace(roleBo.getNamespaceCode());
identityManagementRoleDocument.setEditing(true);
identityManagementRoleDocument.setPermissions(loadPermissions(
getDataObjectService().findMatching(RolePermissionBo.class,
QueryByCriteria.Builder.forAttribute(KimConstants.PrimaryKeyConstants.SUB_ROLE_ID, role.getId()).build()).getResults()));
identityManagementRoleDocument.setResponsibilities(loadResponsibilities(
getDataObjectService().findMatching(RoleResponsibilityBo.class,
QueryByCriteria.Builder.forAttribute(KimConstants.PrimaryKeyConstants.SUB_ROLE_ID, role.getId()).build()).getResults()));
loadResponsibilityRoleRspActions(identityManagementRoleDocument);
identityManagementRoleDocument.setMembers(loadRoleMembers(identityManagementRoleDocument, roleBo.getMembers()));
loadMemberRoleRspActions(identityManagementRoleDocument);
identityManagementRoleDocument.setDelegations(loadRoleDocumentDelegations(identityManagementRoleDocument, getRoleDelegations(roleBo.getId())));
//Since delegation members are flattened out on the UI...
setDelegationMembersInDocument(identityManagementRoleDocument);
identityManagementRoleDocument.setKimType(KimTypeBo.to(roleBo.getKimRoleType()));
}
示例2: loadRoleDoc
import org.kuali.rice.kim.document.IdentityManagementRoleDocument; //导入方法依赖的package包/类
@SuppressWarnings("unchecked")
public void loadRoleDoc(IdentityManagementRoleDocument identityManagementRoleDocument, Role role){
Map<String, String> criteria = new HashMap<String, String>();
criteria.put(KimConstants.PrimaryKeyConstants.ROLE_ID, role.getId());
RoleBo roleBo = getBusinessObjectService().findByPrimaryKey(RoleBo.class, criteria);
Map<String, String> subClassCriteria = new HashMap<String, String>();
subClassCriteria.put(KimConstants.PrimaryKeyConstants.SUB_ROLE_ID, role.getId());
identityManagementRoleDocument.setRoleId(roleBo.getId());
identityManagementRoleDocument.setKimType(KimTypeBo.to(roleBo.getKimRoleType()));
identityManagementRoleDocument.setRoleTypeName(roleBo.getKimRoleType().getName());
identityManagementRoleDocument.setRoleTypeId(roleBo.getKimTypeId());
identityManagementRoleDocument.setRoleName(roleBo.getName());
identityManagementRoleDocument.setRoleDescription(roleBo.getDescription());
identityManagementRoleDocument.setActive(roleBo.isActive());
identityManagementRoleDocument.setRoleNamespace(roleBo.getNamespaceCode());
identityManagementRoleDocument.setEditing(true);
identityManagementRoleDocument.setPermissions(loadPermissions(
(List<RolePermissionBo>) getBusinessObjectService().findMatching(RolePermissionBo.class,
subClassCriteria)));
identityManagementRoleDocument.setResponsibilities(loadResponsibilities(
(List<RoleResponsibilityBo>) getBusinessObjectService().findMatching(RoleResponsibilityBo.class,
subClassCriteria)));
loadResponsibilityRoleRspActions(identityManagementRoleDocument);
identityManagementRoleDocument.setMembers(loadRoleMembers(identityManagementRoleDocument, roleBo.getMembers()));
loadMemberRoleRspActions(identityManagementRoleDocument);
identityManagementRoleDocument.setDelegations(loadRoleDocumentDelegations(identityManagementRoleDocument, getRoleDelegations(roleBo.getId())));
//Since delegation members are flattened out on the UI...
setDelegationMembersInDocument(identityManagementRoleDocument);
identityManagementRoleDocument.setKimType(KimTypeBo.to(roleBo.getKimRoleType()));
}