Class SpaceAccessController

    • Method Detail

      • isUserAuthorized

        public boolean isUserAuthorized​(String userId,
                                        String spaceId,
                                        AccessControlContext context)
        Description copied from interface: AccessController
        Checks if the specified user may access the specified object.
        Specified by:
        isUserAuthorized in interface AccessController<String>
        Parameters:
        userId - the unique identifier of the user.
        spaceId - the object to be accessed.
        context - the context in which the object is accessed.
        Returns:
        true if access is granted - false otherwise.
      • fillUserRoles

        protected void fillUserRoles​(Set<SilverpeasRole> userRoles,
                                     AccessControlContext context,
                                     String userId,
                                     String spaceId)
        Description copied from class: AbstractAccessController
        Fills in the specified set the roles the user plays for the given resource in Silverpeas according to the specified access context.
        Overrides:
        fillUserRoles in class AbstractAccessController<String>
        Parameters:
        userRoles - the set to fill in.
        context - the context defining the type of access with some additional parameters.
        userId - the unique identifier of the user.
        spaceId - the resource in Silverpeas accessed by the user.
      • hasUserSpaceManagementAuthorization

        public boolean hasUserSpaceManagementAuthorization​(String userId,
                                                           String spaceId,
                                                           AccessControlContext context)
        Description copied from interface: SpaceAccessControl
        Checks if the specified user may manage the specified space represented by its identifier.
        Specified by:
        hasUserSpaceManagementAuthorization in interface SpaceAccessControl
        Parameters:
        userId - the unique identifier of the user.
        spaceId - the full identifier of a space.
        context - the context in which the space is accessed.
        Returns:
        true if space management is granted, false otherwise.