Interface SpacePermissionQueryBuilder

  • All Known Implementing Classes:
    SpacePermissionQueryBuilderImpl

    @Internal
    public interface SpacePermissionQueryBuilder
    A centralised place for construction of database query conditions to filter or join on the "spacepermissions" table. This could be extended to support query languages other than HQL in future.
    • Method Detail

      • getHqlPermissionFilterString

        String getHqlPermissionFilterString​(String spacePermissionTableAlias)
        Creates an HQL string of conditions / filter to add to the "WHERE" clause of an HQL query, filtering down to SpacePermission rows which match / grant access to the user. Note: substituteHqlQueryParameters(org.hibernate.query.Query) MUST be called subsequently, to substitute in the required parameters.
        Parameters:
        spacePermissionTableAlias - alias of the SpacePermission table being queried
        Returns:
        an HQL string of conditions, to be appended as part of the "WHERE" clause
      • getUser

        @Nullable ConfluenceUser getUser()
        Returns the user this query builder was constructed for. Will be null for anonymous.
      • getPermissionType

        default String getPermissionType()
        Returns:
        permission type
        Since:
        7.11.0