org.xnap.search
Interface Search

All Known Subinterfaces:
LimeWireSearch, OpenNapBrowseInterface
All Known Implementing Classes:
AbstractSearch, DefaultLimeWireSearch, FreewaySearch, GiFTSearch, JTellaSearch, LibrarySearch, LimeWireBrowse, OpenNapBrowse, OpenNapDirectBrowse, OpenNapMetaBrowse, OpenNapSearch, OvernetSearch, SearchContainer

public interface Search

Defines the requirements for classes that provide search support.

start() is called first. If the user aborts the search stop() is called.

After stop() has been called start() might be called again to requery the search.


Method Summary
 javax.swing.Action[] getActions()
          Returns additional actions for this search that can be performed besides stop and requery.
 SearchFilter getFilter()
          Returns the search filter that was used to find the results.
 java.lang.String getName()
          Returns a string that should be shown to the user.
 java.lang.String getStatus()
          Returns a string that describes the current status.
 boolean isDone()
          Returns true, if this search is finished and can not be started again.
 boolean showTree()
          Returns true, if a tree should be shown next to search results.
 void start(SearchHandler handler)
          Starts this search.
 void stop()
          Cancels this search.
 

Method Detail

getActions

javax.swing.Action[] getActions()
Returns additional actions for this search that can be performed besides stop and requery.


getFilter

SearchFilter getFilter()
Returns the search filter that was used to find the results. This is also used for double fitering.

Returns:
null, if no filter was used; the filter, otherwise

getName

java.lang.String getName()
Returns a string that should be shown to the user.


getStatus

java.lang.String getStatus()
Returns a string that describes the current status.


isDone

boolean isDone()
Returns true, if this search is finished and can not be started again.


showTree

boolean showTree()
Returns true, if a tree should be shown next to search results.


start

void start(SearchHandler handler)
Starts this search.

Parameters:
handler - the object that handles the results

stop

void stop()
Cancels this search.



Copyright © 2001-2005 XNap Team. All Rights Reserved.