Interface GroupRoleProvider

All Superinterfaces:
org.opencastproject.security.api.GroupProvider, org.opencastproject.security.api.RoleProvider
All Known Implementing Classes:
JpaGroupRoleProvider

public interface GroupRoleProvider extends org.opencastproject.security.api.GroupProvider, org.opencastproject.security.api.RoleProvider
  • Method Details

    • getRolesForUser

      List<org.opencastproject.security.api.Role> getRolesForUser(String userName)
      Specified by:
      getRolesForUser in interface org.opencastproject.security.api.RoleProvider
      See Also:
      • RoleProvider.getRolesForUser(String)
    • getRolesForGroup

      List<org.opencastproject.security.api.Role> getRolesForGroup(String groupName)
      Specified by:
      getRolesForGroup in interface org.opencastproject.security.api.GroupProvider
      See Also:
      • RoleProvider.getRolesForUser(String)
    • getOrganization

      String getOrganization()
      Specified by:
      getOrganization in interface org.opencastproject.security.api.RoleProvider
      See Also:
      • RoleProvider.getOrganization()
    • updateGroupMembershipFromRoles

      void updateGroupMembershipFromRoles(String userName, String orgId, List<String> roleList)
      Updates a user's group membership
      Parameters:
      userName - the username
      orgId - the user's organization
      roleList - the list of group role names
    • addGroup

      void addGroup(org.opencastproject.security.impl.jpa.JpaGroup group) throws org.opencastproject.security.api.UnauthorizedException
      Adds or updates a group to the persistence.
      Parameters:
      group - the group to add
      Throws:
      org.opencastproject.security.api.UnauthorizedException
    • getGroups

      Iterator<org.opencastproject.security.api.Group> getGroups()
      Getting all groups
      Returns:
      Iterator<Group> persisted groups
    • updateGroup

      void updateGroup(String groupId, String name, String description, String roles, String users) throws org.opencastproject.util.NotFoundException, org.opencastproject.security.api.UnauthorizedException
      Update a group
      Parameters:
      groupId - the id of the group to update
      name - the name to update
      description - the description to update
      roles - the roles to update
      users - the users to update
      Throws:
      org.opencastproject.util.NotFoundException - if the group is not found
      org.opencastproject.security.api.UnauthorizedException - if the user does not have rights to update the group