Class PeopleFlowRequestGeneratorImpl

java.lang.Object
org.kuali.rice.kew.impl.peopleflow.PeopleFlowRequestGeneratorImpl
All Implemented Interfaces:
PeopleFlowRequestGenerator

public class PeopleFlowRequestGeneratorImpl extends Object implements PeopleFlowRequestGenerator
Reference implementation of the PeopleFlowRequestGenerator which is responsible for generating Action Requests from a PeopleFlowDefinition.
Author:
Kuali Rice Team (rice.collab@kuali.org)
  • Field Details

  • Constructor Details

    • PeopleFlowRequestGeneratorImpl

      public PeopleFlowRequestGeneratorImpl()
  • Method Details

    • generateRequests

      public List<ActionRequestValue> generateRequests(RouteContext routeContext, org.kuali.rice.kew.api.peopleflow.PeopleFlowDefinition peopleFlow, org.kuali.rice.kew.api.action.ActionRequestType actionRequested)
      Specified by:
      generateRequests in interface PeopleFlowRequestGenerator
    • generateRequestForMember

      protected void generateRequestForMember(org.kuali.rice.kew.impl.peopleflow.PeopleFlowRequestGeneratorImpl.Context context, org.kuali.rice.kew.api.peopleflow.PeopleFlowMember member)
    • generateRequestsForRoleMember

      protected List<ActionRequestValue> generateRequestsForRoleMember(org.kuali.rice.kew.impl.peopleflow.PeopleFlowRequestGeneratorImpl.Context context, org.kuali.rice.kew.api.peopleflow.PeopleFlowMember member)
      generates requests for a PeopleFlow member of type Role.

      Will resolve role qualifiers through the appropriate PeopleFlowTypeService, and if multiple qualifier maps are generated, it can generate multiple request trees. parent requests

      Parameters:
      context - the context for request generation
      member - the PeopleFlow member, which is assumed to be of MemberType ROLE
      Returns:
      a list of root action requests that were generated, or an empty list if no role members were resolved
    • generateDelegationRequestsForRoleMember

      protected void generateDelegationRequestsForRoleMember(org.kuali.rice.kew.impl.peopleflow.PeopleFlowRequestGeneratorImpl.Context context, ActionRequestValue parentRequest, org.kuali.rice.kew.api.peopleflow.PeopleFlowMember member, Map<String,String> roleQualifiers)
      Generates any needed requests for the given PeopleFlowDelegate.

      It is assumed that the given member is a Role.

      Parameters:
      context - the context for request generation
      parentRequest - an action request that was generated for the given member
      member - the PeopleFlow member, which should contain the given delegate
      roleQualifiers - member's qualifiers
    • generateDelegationToRoleRequests

      protected void generateDelegationToRoleRequests(org.kuali.rice.kew.impl.peopleflow.PeopleFlowRequestGeneratorImpl.Context context, ActionRequestValue parentRequest, org.kuali.rice.kew.api.peopleflow.PeopleFlowMember member, org.kuali.rice.kew.api.peopleflow.PeopleFlowDelegate delegate)
      Generates any needed requests for the given PeopleFlowDelegate.

      It is assumed that the given member has the given delegate configured.

      Parameters:
      context - the context for request generation
      parentRequest - an action request that was generated for the given member
      member - the PeopleFlow member, which should contain the given delegate
      delegate - the delegate, assumed to be of MemberType ROLE, to generate a request to
    • loadRoleQualifiers

      protected List<Map<String,String>> loadRoleQualifiers(org.kuali.rice.kew.impl.peopleflow.PeopleFlowRequestGeneratorImpl.Context context, String roleId)
      Uses the appropriate PeopleFlowTypeService to get the role qualifier maps for the given document and role.

      Note that the PeopleFlowTypeService is selected based on the type id of the PeopleFlow.

      Parameters:
      context - the context for request generation
      roleId - the ID of the role for whom qualifiers are being loaded
      Returns:
      the qualifier maps, or an empty list if there are none
    • getTypeRepositoryService

      public org.kuali.rice.kew.api.repository.type.KewTypeRepositoryService getTypeRepositoryService()
    • setTypeRepositoryService

      public void setTypeRepositoryService(org.kuali.rice.kew.api.repository.type.KewTypeRepositoryService typeRepositoryService)
    • getRoleService

      public org.kuali.rice.kim.api.role.RoleService getRoleService()
    • setRoleService

      public void setRoleService(org.kuali.rice.kim.api.role.RoleService roleService)