Interface IdentityHelperService

All Known Implementing Classes:
IdentityHelperServiceImpl

public interface IdentityHelperService
A simple helper service in KEW for interacting with the KIM identity management services. Some of the methods on here exist solely for the purpose of assisting with the piece-by-piece migration of KEW to use the KIM services.
Author:
Kuali Rice Team (rice.collab@kuali.org)
  • Method Summary

    Modifier and Type
    Method
    Description
    org.kuali.rice.kim.api.group.Group
    getGroup(String groupId)
    Returns the Group for the given groupId.
    org.kuali.rice.kim.api.group.Group
    getGroup(GroupId groupId)
    Returns the Group for the given GroupId.
    org.kuali.rice.kim.api.group.Group
    getGroupByName(String namespaceCode, String name)
    Returns the Group for the given namespaceCode and name.
    getIdForGroupName(String namespace, String groupName)
     
     
    org.kuali.rice.kim.api.identity.Person
    getPerson(String principalId)
    Returns the Person for the given principal id.
    org.kuali.rice.kim.api.identity.Person
    Returns the Person for the given employee id.
    org.kuali.rice.kim.api.identity.Person
    Returns the Person for the given principal name.
    org.kuali.rice.kim.api.identity.principal.Principal
    getPrincipal(String principalId)
    Returns the KimPrincipal for the given principal id.
    org.kuali.rice.kim.api.identity.principal.Principal
    getPrincipal(org.kuali.rice.kew.api.user.UserId userId)
    Returns the principal for the given UserId.
    org.kuali.rice.kim.api.identity.principal.Principal
    Returns the KimPrincipal for the given principal name.
    Returns the Recipient for the given principalId.
    org.kuali.rice.kim.api.identity.principal.Principal
    Returns the principal for the "system user".
    void
    Checks that the given principalId is valid.
  • Method Details

    • getIdForPrincipalName

      String getIdForPrincipalName(String principalName)
    • getIdForGroupName

      String getIdForGroupName(String namespace, String groupName)
    • getPrincipal

      org.kuali.rice.kim.api.identity.principal.Principal getPrincipal(String principalId)
      Returns the KimPrincipal for the given principal id. Throws an exception if the principal id cannot be resolved to a principal.
      Throws:
      org.kuali.rice.core.api.exception.RiceIllegalArgumentException - if the principal id cannot be resolved to a principal.
    • getPrincipalByPrincipalName

      org.kuali.rice.kim.api.identity.principal.Principal getPrincipalByPrincipalName(String principalName)
      Returns the KimPrincipal for the given principal name. Throws an exception if the principal name cannot be resolved to a principal.
      Throws:
      org.kuali.rice.core.api.exception.RiceIllegalArgumentException - if the principal name cannot be resolved to a principal
    • getPerson

      org.kuali.rice.kim.api.identity.Person getPerson(String principalId)
      Returns the Person for the given principal id. Throws an exception if the principal id cannot be resolved to a person.
      Throws:
      org.kuali.rice.core.api.exception.RiceIllegalArgumentException - if the principal id cannot be resolved to a person.
    • getPersonByPrincipalName

      org.kuali.rice.kim.api.identity.Person getPersonByPrincipalName(String principalName)
      Returns the Person for the given principal name. Throws an exception if the principal name cannot be resolved to a person.
      Throws:
      org.kuali.rice.core.api.exception.RiceIllegalArgumentException - if the principal name cannot be resolved to a person.
    • getPersonByEmployeeId

      org.kuali.rice.kim.api.identity.Person getPersonByEmployeeId(String employeeId)
      Returns the Person for the given employee id. Throws an exception if the principal name cannot be resolved to a person.
      Throws:
      org.kuali.rice.core.api.exception.RiceIllegalArgumentException - if the principal name cannot be resolved to a person.
    • validatePrincipalId

      void validatePrincipalId(String principalId)
      Checks that the given principalId is valid. Throws a RiceRuntimeException if it is not.
      Throws:
      org.kuali.rice.core.api.exception.RiceIllegalArgumentException - if the given principalId is valid
    • getPrincipal

      org.kuali.rice.kim.api.identity.principal.Principal getPrincipal(org.kuali.rice.kew.api.user.UserId userId)
      Returns the principal for the given UserId.
      Throws:
      org.kuali.rice.core.api.exception.RiceIllegalArgumentException - if the given UserId does not resolve to a valid principal
    • getGroup

      org.kuali.rice.kim.api.group.Group getGroup(String groupId)
      Returns the Group for the given groupId. Throws an exception if the groupId cannot be resolved to a group.
      Throws:
      org.kuali.rice.core.api.exception.RiceIllegalArgumentException - if the groupId cannot be resolved to a group.
    • getGroup

      org.kuali.rice.kim.api.group.Group getGroup(GroupId groupId)
      Returns the Group for the given GroupId. Throws an exception if the groupId cannot be resolved to a group.
      Throws:
      org.kuali.rice.core.api.exception.RiceIllegalArgumentException - if the GroupId cannot be resolved to a group.
    • getGroupByName

      org.kuali.rice.kim.api.group.Group getGroupByName(String namespaceCode, String name)
      Returns the Group for the given namespaceCode and name. Throws an exception if the namespaceCode and name cannot be resolved to a group.
      Throws:
      org.kuali.rice.core.api.exception.RiceIllegalArgumentException - if the namespaceCode and name cannot be resolved to a group.
    • getPrincipalRecipient

      Recipient getPrincipalRecipient(String principalId)
      Returns the Recipient for the given principalId. Throws an exception if the principalId cannot be resolved to a recipient.
      Throws:
      org.kuali.rice.core.api.exception.RiceIllegalArgumentException - if the principalId cannot be resolved to a recipient
    • getSystemPrincipal

      org.kuali.rice.kim.api.identity.principal.Principal getSystemPrincipal()
      Returns the principal for the "system user". This is a user that can be used in the cases where an actual user cannot be determined.