com.atlassian.jira.issue.search
Interface SearchContext

All Known Implementing Classes:
SearchContextImpl

public interface SearchContext


Method Summary
 java.util.List<IssueContext> getAsIssueContexts()
          Gets the search context as a list of IssueContext objects
 java.util.List<java.lang.String> getIssueTypeIds()
          Issue ids as Strings
 org.ofbiz.core.entity.GenericValue getOnlyProject()
           
 java.util.List getProjectCategoryIds()
          Returns selected categories
 java.util.List<java.lang.Long> getProjectIds()
          Project ids as Longs.
 boolean isForAnyIssueTypes()
          Returns true if no specific issue types have been selected
 boolean isForAnyProjects()
          Returns whether the context is global or not.
 boolean isSingleProjectContext()
           
 void verify()
          Verifies that all issue types and projects in the context actually still exists.
 

Method Detail

isForAnyProjects

boolean isForAnyProjects()
Returns whether the context is global or not. A context is global when there are no project restrictions and no project category restrictions.

Returns:
boolean

isForAnyIssueTypes

boolean isForAnyIssueTypes()
Returns true if no specific issue types have been selected

Returns:
boolean

isSingleProjectContext

boolean isSingleProjectContext()

getProjectCategoryIds

java.util.List getProjectCategoryIds()
Returns selected categories

Returns:
Empty list if no categories were selected

getProjectIds

java.util.List<java.lang.Long> getProjectIds()
Project ids as Longs.

Returns:
List of Long objects, possibly empty.

getOnlyProject

org.ofbiz.core.entity.GenericValue getOnlyProject()

getIssueTypeIds

java.util.List<java.lang.String> getIssueTypeIds()
Issue ids as Strings

Returns:
List of issue type ids possibly empty.

getAsIssueContexts

java.util.List<IssueContext> getAsIssueContexts()
Gets the search context as a list of IssueContext objects

Returns:
List of IssueContext. If no issue types or projects selected. A blank issue context is returned. Never null.

verify

void verify()
Verifies that all issue types and projects in the context actually still exists. This might not be the case. Also removes any projects or issue types from this SearchContext that do not (any longer) exist in the backing store.



Copyright © 2002-2010 Atlassian. All Rights Reserved.