Class CQPermissions

    • Constructor Detail

      • CQPermissions

        public CQPermissions​(T client)
    • Method Detail

      • changePermissions

        public com.fasterxml.jackson.databind.JsonNode changePermissions​(String authorizableId,
                                                                         String path,
                                                                         boolean read,
                                                                         boolean modify,
                                                                         boolean create,
                                                                         boolean delete,
                                                                         boolean acl_read,
                                                                         boolean acl_edit,
                                                                         boolean replicate,
                                                                         int... expectedStatus)
                                                                  throws org.apache.sling.testing.clients.ClientException
        Changes permissions for an authorizable.
        Parameters:
        authorizableId - the authorizable id
        path - path
        read - read permission
        modify - modify permission
        create - createGroup permission
        delete - delete permission
        acl_read - read acl
        acl_edit - edit acl
        replicate - replication
        expectedStatus - list of allowed HTTP Status to be returned. If not set, http status 200 (OK) is assumed.
        Returns:
        Json node containing resulting permissions
        Throws:
        org.apache.sling.testing.clients.ClientException - If something fails during request/response cycle
      • getPermissions

        public com.fasterxml.jackson.databind.JsonNode getPermissions​(String authorizableId,
                                                                      String path,
                                                                      int depth,
                                                                      int... expectedStatus)
                                                               throws org.apache.sling.testing.clients.ClientException
        Get permissions for an authorizable.
        Parameters:
        authorizableId - the Id of the authorizable
        path - path
        depth - depth
        expectedStatus - list of allowed HTTP Status to be returned. If not set, http status 200 (OK) is assumed.
        Returns:
        the root JsonNode
        Throws:
        org.apache.sling.testing.clients.ClientException - If something fails during request/response cycle