com.atlassian.jira.jql.permission
Interface ClauseSanitiser

All Known Subinterfaces:
ClausePermissionHandler
All Known Implementing Classes:
DefaultClausePermissionHandler, IssueClauseValueSanitiser, NoOpClauseSanitiser, ProjectClauseValueSanitiser

public interface ClauseSanitiser

Deals with the sanitisation of clauses based on the given user.

Since:
v4.0

Method Summary
 Clause sanitise(com.atlassian.crowd.embedded.api.User user, TerminalClause clause)
          Given a user and a clause, will return a sanitised clause that when possible will not contain any information that the specified user does not have permission to see.
 

Method Detail

sanitise

Clause sanitise(com.atlassian.crowd.embedded.api.User user,
                TerminalClause clause)

Given a user and a clause, will return a sanitised clause that when possible will not contain any information that the specified user does not have permission to see. For example, if the given clause names a project that the user cannot browse, a sanitiser might return a new clause with the name of the project replaced with the id.

It is important that the returned clause is equivalent to the input clause, within the constraints of the permissible clauses for the specified user.

Parameters:
user - the user performing the search
clause - the clause to be sanitised
Returns:
the sanitised clause; never null.


Copyright © 2002-2014 Atlassian. All Rights Reserved.