org.jivesoftware.spark.search
Class SearchManager

java.lang.Object
  extended by org.jivesoftware.spark.search.SearchManager

public class SearchManager
extends java.lang.Object

Users of the SearchManager can add their own Searchable objects to the Spark search service. This allows for a pluggable search architecture by simply plugging into the find area of the bottom of Spark.


Method Summary
 void addSearchService(Searchable searchable)
          Add your own Searchable service.The UI will take immediate effect to indicate that this search service is now available as an option.
static SearchManager getInstance()
          Returns the singleton instance of SearchManager, creating it if necessary.
 java.util.Collection<Searchable> getSearchServices()
          Returns all registered search services.
 SearchService getSearchServiceUI()
           
 void removeSearchService(Searchable searchable)
          Remove the Searchable service.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getInstance

public static SearchManager getInstance()
Returns the singleton instance of SearchManager, creating it if necessary.

Returns:
the singleton instance of SearchManager

addSearchService

public void addSearchService(Searchable searchable)
Add your own Searchable service.The UI will take immediate effect to indicate that this search service is now available as an option.

Parameters:
searchable - the search service.

removeSearchService

public void removeSearchService(Searchable searchable)
Remove the Searchable service. The UI will take immediate effect to indicate that this search service is no longer an option.

Parameters:
searchable - the searchable object to remove.

getSearchServices

public java.util.Collection<Searchable> getSearchServices()
Returns all registered search services.

Returns:
the collection of search services.

getSearchServiceUI

public SearchService getSearchServiceUI()