com.atlassian.jira.issue.search.searchers
Class MockIssueSearcher<T extends SearchableField>

java.lang.Object
  extended by com.atlassian.jira.issue.search.searchers.MockIssueSearcher<T>
All Implemented Interfaces:
IssueSearcher<T>
Direct Known Subclasses:
MockCustomFieldSearcher, MockSystemSearcher

public class MockIssueSearcher<T extends SearchableField>
extends Object
implements IssueSearcher<T>

A simple mock implementation of the IssueSearcher interface for testsing.

Since:
v4.0

Field Summary
 
Fields inherited from interface com.atlassian.jira.issue.search.searchers.IssueSearcher
log
 
Constructor Summary
MockIssueSearcher(String id)
           
 
Method Summary
 boolean equals(Object o)
           
 T getField()
           
 String getId()
           
 SearcherInformation<T> getSearchInformation()
          Provides an object that contains information about the Searcher.
 SearchInputTransformer getSearchInputTransformer()
          Provides an object that will allow you to transform raw request parameters to field holder values and field holder values to Clause search representations.
 SearchRenderer getSearchRenderer()
          Provides an object that will allow you to render the edit and view html for a searcher.
 int hashCode()
           
 void init(T field)
          Initialises the searcher with a given field.
 void setInformation(SearcherInformation<T> information)
           
 void setRenderer(SearchRenderer renderer)
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MockIssueSearcher

public MockIssueSearcher(String id)
Method Detail

getId

public String getId()

setInformation

public void setInformation(SearcherInformation<T> information)

init

public void init(T field)
Description copied from interface: IssueSearcher
Initialises the searcher with a given field.

Specified by:
init in interface IssueSearcher<T extends SearchableField>
Parameters:
field - the field object. This may be null. (So you can have searchers on non-fields)

getField

public T getField()

getSearchInformation

public SearcherInformation<T> getSearchInformation()
Description copied from interface: IssueSearcher
Provides an object that contains information about the Searcher.

Specified by:
getSearchInformation in interface IssueSearcher<T extends SearchableField>
Returns:
the search information provider for this searcher.

getSearchInputTransformer

public SearchInputTransformer getSearchInputTransformer()
Description copied from interface: IssueSearcher
Provides an object that will allow you to transform raw request parameters to field holder values and field holder values to Clause search representations.

Specified by:
getSearchInputTransformer in interface IssueSearcher<T extends SearchableField>
Returns:
the search input handler for this searcher.

getSearchRenderer

public SearchRenderer getSearchRenderer()
Description copied from interface: IssueSearcher
Provides an object that will allow you to render the edit and view html for a searcher. This also provides methods that indicate if the view and edit methods should be invoked.

Specified by:
getSearchRenderer in interface IssueSearcher<T extends SearchableField>
Returns:
the search renderer for this searcher.

setRenderer

public void setRenderer(SearchRenderer renderer)

equals

public boolean equals(Object o)
Overrides:
equals in class Object

hashCode

public int hashCode()
Overrides:
hashCode in class Object


Copyright © 2002-2014 Atlassian. All Rights Reserved.