org.xnap.plugin.opennap.net
Class OpenNapSearch

java.lang.Object
  extended by org.xnap.search.AbstractSearch
      extended by org.xnap.plugin.opennap.net.OpenNapSearch
All Implemented Interfaces:
ExceptionListener, Search

public class OpenNapSearch
extends AbstractSearch
implements ExceptionListener

Implements an OpenNap search on a set of servers.


Field Summary
static int PRIORITY_HIGH
           
static int PRIORITY_LOW
           
 
Constructor Summary
OpenNapSearch(SearchFilter filter, int priority, OpenNapServer[] servers)
           
 
Method Summary
 void exceptionThrown(java.lang.Exception e)
           
 int getPriority()
           
 SearchRequestMessage getRequest()
           
 java.lang.String getStatus()
          Returns a string that describes the current status.
 boolean isDone()
          Returns true, if this search can not be canceled.
 void start(SearchHandler handler)
          Starts this search.
 void stop()
          Cancels this search.
 
Methods inherited from class org.xnap.search.AbstractSearch
getActions, getFilter, getName, showTree
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

PRIORITY_HIGH

public static int PRIORITY_HIGH

PRIORITY_LOW

public static int PRIORITY_LOW
Constructor Detail

OpenNapSearch

public OpenNapSearch(SearchFilter filter,
                     int priority,
                     OpenNapServer[] servers)
Method Detail

exceptionThrown

public void exceptionThrown(java.lang.Exception e)
Specified by:
exceptionThrown in interface ExceptionListener

getPriority

public int getPriority()

getRequest

public SearchRequestMessage getRequest()

getStatus

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

Specified by:
getStatus in interface Search

isDone

public boolean isDone()
Returns true, if this search can not be canceled.

Specified by:
isDone in interface Search

start

public void start(SearchHandler handler)
Starts this search.

Specified by:
start in interface Search
Parameters:
handler - the object that handles the results

stop

public void stop()
Cancels this search.

Specified by:
stop in interface Search


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