public class

QueryCacheImpl

extends Object
implements QueryCache
java.lang.Object
   ↳ com.atlassian.jira.bc.issue.search.QueryCacheImpl

Class Overview

The default implementation for the QueryCache The cache is stored in a common request cache, so caches are shared amongst instances.

Summary

Public Constructors
QueryCacheImpl()
Public Methods
Collection<ClauseHandler> getClauseHandlers(User searcher, String jqlClauseName)
Retrieve the collection of ClauseHandlers registered for the User jqlClauseName pair.
Boolean getDoesQueryFitFilterFormCache(User searcher, Query query)
Retrieve the result of the last doesQueryFitFiterForm operation in the current thread.
QueryContext getQueryContextCache(User searcher, Query query)
Retrieve the result of the last getQueryContext operation in the current thread for the User Query pair.
QueryContext getSimpleQueryContextCache(User searcher, Query query)
Retrieve the result of the last getSimpleQueryContext operation in the current thread for the User Query pair.
List<QueryLiteral> getValues(QueryCreationContext context, Operand operand, TerminalClause jqlClause)
Retrieve the list of QueryLiterals registered for the QueryCreationContext Operand jqlClause triplet.
void setClauseHandlers(User searcher, String jqlClauseName, Collection<ClauseHandler> clauseHandlers)
Set the cached result of a getSimpleQueryContext operation on the User Query pair.
void setDoesQueryFitFilterFormCache(User searcher, Query query, boolean doesItFit)
Set the cached result of a doesQueryFitFiterForm operation on the User Query pair.
void setQueryContextCache(User searcher, Query query, QueryContext queryContext)
Set the cached result of a getQueryContext operation on the User Query pair.
void setSimpleQueryContextCache(User searcher, Query query, QueryContext queryContext)
Set the cached result of a getSimpleQueryContext operation on the User Query pair.
void setValues(QueryCreationContext context, Operand operand, TerminalClause jqlClause, List<QueryLiteral> values)
Set the cached result of a getValues operation on the for the QueryCreationContext Operand jqlClause triplet.
[Expand]
Inherited Methods
From class java.lang.Object
From interface com.atlassian.jira.bc.issue.search.QueryCache

Public Constructors

public QueryCacheImpl ()

Public Methods

public Collection<ClauseHandler> getClauseHandlers (User searcher, String jqlClauseName)

Retrieve the collection of ClauseHandlers registered for the User jqlClauseName pair.

Parameters
searcher the user who is performing the search
jqlClauseName the jQLClauseName for which to find the result for; cannot be null.
Returns

public Boolean getDoesQueryFitFilterFormCache (User searcher, Query query)

Retrieve the result of the last doesQueryFitFiterForm operation in the current thread. for the User Query pair.

Parameters
searcher the user who is performing the search
query the query for which to find the result for; cannot be null.
Returns
  • the last result of the doesQueryFitFiterForm operation for the User Query pair in the current thread, or null if the operation has yet to be performed.

public QueryContext getQueryContextCache (User searcher, Query query)

Retrieve the result of the last getQueryContext operation in the current thread for the User Query pair.

Parameters
searcher the user who is performing the search
query the query for which to find the result for; cannot be null.
Returns
  • the last result of the getQueryContext operation for the User Query pair in the current thread, or null if the operation has yet to be performed.

public QueryContext getSimpleQueryContextCache (User searcher, Query query)

Retrieve the result of the last getSimpleQueryContext operation in the current thread for the User Query pair.

Parameters
searcher the user who is performing the search
query the query for which to find the result for; cannot be null.
Returns
  • the last result of the getSimpleQueryContext operation for the User Query pair in the current thread, or null if the operation has yet to be performed.

public List<QueryLiteral> getValues (QueryCreationContext context, Operand operand, TerminalClause jqlClause)

Retrieve the list of QueryLiterals registered for the QueryCreationContext Operand jqlClause triplet.

Parameters
context the query context of the search, which cannot be null.
operand the Operand which cannot be null
jqlClause the jQLClause for which to find the result for; cannot be null.
Returns

public void setClauseHandlers (User searcher, String jqlClauseName, Collection<ClauseHandler> clauseHandlers)

Set the cached result of a getSimpleQueryContext operation on the User Query pair. The cache result is only held for the current thread.

Parameters
searcher the user who is performing the search
jqlClauseName the jQLClauseName for which to store the result under; cannot be null.
clauseHandlers the collection of ClauseHandlers User ClauseHandler

public void setDoesQueryFitFilterFormCache (User searcher, Query query, boolean doesItFit)

Set the cached result of a doesQueryFitFiterForm operation on the User Query pair. The cache result is only held for the current thread.

Parameters
searcher the user who is performing the search
query the query for which to store the result under; cannot be null
doesItFit the result of a doesSearchRequestFitNavigator operation for the. User Query

public void setQueryContextCache (User searcher, Query query, QueryContext queryContext)

Set the cached result of a getQueryContext operation on the User Query pair. The cache result is only held for the current thread.

Parameters
searcher the user who is performing the search
query the query for which to store the result under; cannot be null.
queryContext the queryContext result to store User Query

public void setSimpleQueryContextCache (User searcher, Query query, QueryContext queryContext)

Set the cached result of a getSimpleQueryContext operation on the User Query pair. The cache result is only held for the current thread.

Parameters
searcher the user who is performing the search
query the query for which to store the result under; cannot be null.
queryContext the querySimpleContext result to store User Query

public void setValues (QueryCreationContext context, Operand operand, TerminalClause jqlClause, List<QueryLiteral> values)

Set the cached result of a getValues operation on the for the QueryCreationContext Operand jqlClause triplet. The cache result is only held for the current thread.

Parameters
context the query context the search is being performed in
operand the Operand which cannot be null
jqlClause the jQLClause for which to store the result under; cannot be null.
values the collection of QueryLiterals