Package org.kuali.rice.kim.document.rule
Class IdentityManagementPersonDocumentRule
java.lang.Object
org.kuali.rice.krad.rules.DocumentRuleBase
org.kuali.rice.kns.rules.DocumentRuleBase
org.kuali.rice.kns.rules.TransactionalDocumentRuleBase
org.kuali.rice.kim.document.rule.IdentityManagementPersonDocumentRule
- All Implemented Interfaces:
AddGroupRule,AddPersonDelegationMemberRule,AddPersonDocumentRoleQualifierRule,AddRoleRule,AddAdHocRoutePersonRule,AddAdHocRouteWorkgroupRule,AddCollectionLineRule,AddNoteRule,ApproveDocumentRule,BusinessRule,CompleteDocumentRule,RouteDocumentRule,SaveDocumentRule,SendAdHocRequestsRule
public class IdentityManagementPersonDocumentRule
extends TransactionalDocumentRuleBase
implements AddGroupRule, AddRoleRule, AddPersonDocumentRoleQualifierRule, AddPersonDelegationMemberRule
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected ActiveRoleMemberHelperprotected AddGroupRuleprotected Class<? extends AddGroupRule>protected AddPersonDelegationMemberRuleprotected Class<? extends AddPersonDelegationMemberRule>protected AddRoleRuleprotected Class<? extends AddRoleRule>protected AttributeValidationHelperprotected IdentityManagementKimDocumentAuthorizer -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleancanModifyEntity(String currentUserPrincipalId, String toModifyPrincipalId) booleancanOverrideEntityPrivacyPreferences(String currentUserPrincipalId, String toModifyPrincipalId) protected booleancheckAffiliationEithOneEMpInfo(List<PersonDocumentAffiliation> affiliations) protected booleancheckAffiliationTypeChange(List<PersonDocumentAffiliation> affiliations) protected booleancheckMultipleDefault(List<? extends PersonDocumentBoDefaultBase> boList, String listName) protected booleancheckPrimaryEmploymentInfo(List<PersonDocumentAffiliation> affiliations) protected booleancheckUniqueAffiliationTypePerCampus(List<PersonDocumentAffiliation> affiliations) protected booleandoesPrincipalIdExist(String principalId) protected booleandoesPrincipalNameExist(String principalName, String principalId) findUniqueQualificationAttributes(PersonDocumentRole role, List<org.kuali.rice.kim.api.type.KimAttributeField> attributeDefinitions) Finds the set of unique qualification attributes for the given roleClass<? extends AddGroupRule>Class<? extends AddRoleRule>protected IdentityManagementKimDocumentAuthorizerprotected org.kuali.rice.kim.api.identity.IdentityServiceprotected org.kuali.rice.kim.api.role.RoleServiceprotected booleanisPersonAnEmployee(List<PersonDocumentAffiliation> affiliations) booleanprocessAddGroup(AddGroupEvent addGroupEvent) booleanprocessAddPersonDelegationMember(AddPersonDelegationMemberEvent addPersonDelegationMemberEvent) booleanprocessAddPersonDocumentRoleQualifier(IdentityManagementPersonDocument document, PersonDocumentRole role, KimDocumentRoleMember kimDocumentRoleMember, int selectedRoleIdx) booleanprocessAddRole(AddRoleEvent addRoleEvent) protected booleanprotected booleanprotected booleansameMembershipQualifications(KimDocumentRoleMember membershipA, KimDocumentRoleMember membershipB, Set<String> uniqueQualifierAttributes) Determines if two seperate memberships have the same qualificationsvoidsetAddGroupRuleClass(Class<? extends AddGroupRule> addGroupRuleClass) Can be overridden by subclasses to indicate the rule class to use when adding groups.voidsetAddRoleRuleClass(Class<? extends AddRoleRule> addRoleRuleClass) Can be overridden by subclasses to indicate the rule class to use when adding roles.protected booleanvalidActiveDatesForDelegations(List<RoleDocumentDelegationMember> delegationMembers) protected booleanprotected booleanprotected booleanvalidateActiveDate(String errorPath, Timestamp activeFromDate, Timestamp activeToDate) protected booleanprotected booleanvalidateDelegationMemberRoleQualifier(List<RoleDocumentDelegationMember> delegationMembers) protected booleanvalidateEntityInformation(boolean isCreatingNew, IdentityManagementPersonDocument personDoc) protected booleanprotected booleanvalidateUniquePersonRoleQualifiersUniqueForMembership(PersonDocumentRole role, KimDocumentRoleMember membershipToCheck, int membershipToCheckIndex, Set<String> uniqueQualifierAttributes, int roleIndex, List<RemotableAttributeError> validationErrors) Checks all the qualifiers for the given membership, so that all qualifiers which should be unique are guaranteed to be uniqueprotected booleanprotected booleanvalidEmployeeIDForAffiliation(List<PersonDocumentAffiliation> affiliations) Methods inherited from class org.kuali.rice.kns.rules.DocumentRuleBase
getDictionaryValidationServiceMethods inherited from class org.kuali.rice.krad.rules.DocumentRuleBase
buildDocumentTypeActionRequestPermissionDetails, buildDocumentTypePermissionDetails, getDataDictionaryService, getDocumentDictionaryService, getGroupService, getKualiConfigurationService, getMaxDictionaryValidationDepth, getPermissionService, getPersonService, hasAdHocRouteCompletion, isAddHocRoutePersonValid, isAddHocRouteWorkgroupValid, isAdHocRouteCompletionToInitiator, isAdHocRouteRecipientsValid, isDocumentAttributesValid, isDocumentOverviewValid, isNoteValid, processAddAdHocRoutePerson, processAddAdHocRouteWorkgroup, processAddCollectionLine, processAddNote, processApproveDocument, processCompleteDocument, processCustomAddAdHocRoutePersonBusinessRules, processCustomAddAdHocRouteWorkgroupBusinessRules, processCustomAddCollectionLineBusinessRules, processCustomAddNoteBusinessRules, processCustomApproveDocumentBusinessRules, processCustomCompleteDocumentBusinessRules, processCustomSendAdHocRequests, processRouteDocument, processSaveDocument, processSendAdHocRequests, setDocumentDictionaryService, setMaxDictionaryValidationDepth, useKimPermission, validateSensitiveDataValue
-
Field Details
-
addGroupRule
-
addRoleRule
-
addPersonDelegationMemberRule
-
authorizer
-
addGroupRuleClass
-
addRoleRuleClass
-
addPersonDelegationMemberRuleClass
-
activeRoleMemberHelper
-
attributeValidationHelper
-
-
Constructor Details
-
IdentityManagementPersonDocumentRule
public IdentityManagementPersonDocumentRule()
-
-
Method Details
-
processCustomSaveDocumentBusinessRules
- Overrides:
processCustomSaveDocumentBusinessRulesin classDocumentRuleBase
-
validateEntityInformation
protected boolean validateEntityInformation(boolean isCreatingNew, IdentityManagementPersonDocument personDoc) -
validDuplicatePrincipalName
-
processCustomRouteDocumentBusinessRules
- Overrides:
processCustomRouteDocumentBusinessRulesin classDocumentRuleBase
-
checkMultipleDefault
protected boolean checkMultipleDefault(List<? extends PersonDocumentBoDefaultBase> boList, String listName) -
checkPrimaryEmploymentInfo
-
checkAffiliationTypeChange
-
validEmployeeIDForAffiliation
-
isPersonAnEmployee
-
checkUniqueAffiliationTypePerCampus
-
checkAffiliationEithOneEMpInfo
-
validateAffiliationAndName
-
doesPrincipalNameExist
-
doesPrincipalIdExist
-
validateRoleQualifier
-
validateUniquePersonRoleQualifiersUniqueForMembership
protected boolean validateUniquePersonRoleQualifiersUniqueForMembership(PersonDocumentRole role, KimDocumentRoleMember membershipToCheck, int membershipToCheckIndex, Set<String> uniqueQualifierAttributes, int roleIndex, List<RemotableAttributeError> validationErrors) Checks all the qualifiers for the given membership, so that all qualifiers which should be unique are guaranteed to be unique- Parameters:
roleIndex- the index of the role on the document (for error reporting purposes)membershipToCheckIndex- the index of the person's membership in the role (for error reporting purposes)- Returns:
- true if all unique values are indeed unique, false otherwise
-
sameMembershipQualifications
protected boolean sameMembershipQualifications(KimDocumentRoleMember membershipA, KimDocumentRoleMember membershipB, Set<String> uniqueQualifierAttributes) Determines if two seperate memberships have the same qualifications- Parameters:
membershipA- the first membership to checkmembershipB- the second membership to checkuniqueQualifierAttributes- the set of qualifier attributes which need to be unique- Returns:
- true if equal, false if otherwise
-
findUniqueQualificationAttributes
public Set<String> findUniqueQualificationAttributes(PersonDocumentRole role, List<org.kuali.rice.kim.api.type.KimAttributeField> attributeDefinitions) Finds the set of unique qualification attributes for the given role- Parameters:
role- the role associated with this personattributeDefinitions- the Map of attribute definitions where we can find out if a KimAttribute is supposed to be unique- Returns:
- a Set of attribute definition ids for qualifications which are supposed to be unique
-
validActiveDatesForRole
-
validActiveDatesForGroup
-
validActiveDatesForDelegations
protected boolean validActiveDatesForDelegations(List<RoleDocumentDelegationMember> delegationMembers) -
validateActiveDate
-
processAddGroup
- Specified by:
processAddGroupin interfaceAddGroupRule
-
processAddRole
- Specified by:
processAddRolein interfaceAddRoleRule
-
processAddPersonDelegationMember
public boolean processAddPersonDelegationMember(AddPersonDelegationMemberEvent addPersonDelegationMemberEvent) - Specified by:
processAddPersonDelegationMemberin interfaceAddPersonDelegationMemberRule
-
getIdentityService
protected org.kuali.rice.kim.api.identity.IdentityService getIdentityService() -
getRoleService
protected org.kuali.rice.kim.api.role.RoleService getRoleService() -
getAuthorizer
protected IdentityManagementKimDocumentAuthorizer getAuthorizer(IdentityManagementPersonDocument document) -
getAddGroupRuleClass
- Returns:
- the addGroupRuleClass
-
setAddGroupRuleClass
Can be overridden by subclasses to indicate the rule class to use when adding groups.- Parameters:
addGroupRuleClass- the addGroupRuleClass to set
-
getAddRoleRuleClass
- Returns:
- the addRoleRuleClass
-
setAddRoleRuleClass
Can be overridden by subclasses to indicate the rule class to use when adding roles.- Parameters:
addRoleRuleClass- the addRoleRuleClass to set
-
getAddGroupRule
- Returns:
- the addGroupRule
-
getAddRoleRule
- Returns:
- the addRoleRule
-
getAddPersonDelegationMemberRule
- Returns:
- the addRoleRule
-
processAddPersonDocumentRoleQualifier
public boolean processAddPersonDocumentRoleQualifier(IdentityManagementPersonDocument document, PersonDocumentRole role, KimDocumentRoleMember kimDocumentRoleMember, int selectedRoleIdx) - Specified by:
processAddPersonDocumentRoleQualifierin interfaceAddPersonDocumentRoleQualifierRule
-
validateDelegationMemberRoleQualifier
protected boolean validateDelegationMemberRoleQualifier(List<RoleDocumentDelegationMember> delegationMembers) -
canModifyEntity
-
canOverrideEntityPrivacyPreferences
-