Follow Techotopia on Twitter

On-line Guides
All Guides
eBook Store
iOS / Android
Linux for Beginners
Office Productivity
Linux Installation
Linux Security
Linux Utilities
Linux Virtualization
Linux Kernel
System/Network Admin
Programming
Scripting Languages
Development Tools
Web Development
GUI Toolkits/Desktop
Databases
Mail Systems
openSolaris
Eclipse Documentation
Techotopia.com
Virtuatopia.com
Answertopia.com

How To Guides
Virtualization
General System Admin
Linux Security
Linux Filesystems
Web Servers
Graphics & Desktop
PC Hardware
Windows
Problem Solutions
Privacy Policy

  




 

 

RSE
Release 3.0

org.eclipse.rse.services.search
Class AbstractSearchResultConfiguration


java.lang.Object
  extended by 
org.eclipse.rse.services.search.AbstractSearchResultConfiguration
All Implemented Interfaces:
IHostSearchResultConfiguration

public abstract class AbstractSearchResultConfiguration
extends Object
implements IHostSearchResultConfiguration

This class represents a search result configuration. A configuration consists of a search target and a search string, and belongs to a search result set. Once a search has been started via a subsystem, the results are stored in the configuration itself. The status of the search can also be queried from the configuration.


Field Summary
protected   Map _containedResults
           
protected   ISearchHandler _searchHandler
           
protected   ISearchService _searchService
           
protected   IHostSearchResultSet parentResultSet
           
protected   Vector results
           
protected   SystemSearchString searchString
           
protected   Object searchTarget
           
protected  int status
           
 
Constructor Summary
AbstractSearchResultConfiguration ( IHostSearchResultSet resultSet, Object searchObject, SystemSearchString string, ISearchService searchService)
          Constructor for a result set configuration.
 
Method Summary
 void addResult ( Object result)
          Adds a search result.
 void addResults ( Object container, IHostSearchResult[] results)
          Adds a set of search results along their associated container
 void cancel ()
          Cancels the search if it is running.
 void dispose ()
          Cancels the search and then removes the search results.
  IHostSearchResult[] getContainedResults ( Object resultContainer)
          Gets the results contained within the resultContainer
  IHostSearchResultSet getParentResultSet ()
          Gets the parent result set.
  Object[] getResults ()
          Gets search results.
 int getResultsSize ()
          Gets the size of the results.
  ISearchHandler getSearchHandler ()
          Gets the search handler.
  ISearchService getSearchService ()
           
  SystemSearchString getSearchString ()
          Gets the search string.
  Object getSearchTarget ()
          Gets the object to be searched.
 int getStatus ()
          Gets the status of the search.
 void removeAndAddResult ( Object oldResult, Object newResult)
          Removes the old result and adds a new result.
 void removeResult ( Object result)
          Removes a search result.
 void removeResults ()
          Removes all search results.
 void setParentResultSet ( IHostSearchResultSet resultSet)
          Sets the parent result set.
 void setSearchHandler ( ISearchHandler searchHandler)
          Sets the search handler
 void setSearchString ( SystemSearchString string)
          Sets the search string.
 void setSearchTarget ( Object searchObject)
          Sets the object to be searched.
 void setStatus (int status)
          Sets the status of the search.
 
Methods inherited from class java.lang. Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

parentResultSet

protected 
IHostSearchResultSet parentResultSet

searchTarget

protected 
Object searchTarget

searchString

protected 
SystemSearchString searchString

results

protected 
Vector results

_containedResults

protected 
Map _containedResults

status

protected int status

_searchService

protected 
ISearchService _searchService

_searchHandler

protected 
ISearchHandler _searchHandler
Constructor Detail

AbstractSearchResultConfiguration

public AbstractSearchResultConfiguration(
IHostSearchResultSet resultSet,
                                         
Object searchObject,
                                         
SystemSearchString string,
                                         
ISearchService searchService)
Constructor for a result set configuration. Sets status to RUNNING.

Parameters:
resultSet - the parent result set.
searchObject - the target of the search.
string - the search string.
Method Detail

setParentResultSet

public void setParentResultSet(
IHostSearchResultSet resultSet)
Description copied from interface: IHostSearchResultConfiguration
Sets the parent result set.

Specified by:
setParentResultSet in interface IHostSearchResultConfiguration
Parameters:
resultSet - the parent result set.

getParentResultSet

public 
IHostSearchResultSet getParentResultSet()
Description copied from interface: IHostSearchResultConfiguration
Gets the parent result set.

Specified by:
getParentResultSet in interface IHostSearchResultConfiguration
Returns:
the parent result set.

getSearchService

public 
ISearchService getSearchService()

setSearchTarget

public void setSearchTarget(
Object searchObject)
Description copied from interface: IHostSearchResultConfiguration
Sets the object to be searched.

Specified by:
setSearchTarget in interface IHostSearchResultConfiguration
Parameters:
searchObject - the object to be searched.

getSearchTarget

public 
Object getSearchTarget()
Description copied from interface: IHostSearchResultConfiguration
Gets the object to be searched.

Specified by:
getSearchTarget in interface IHostSearchResultConfiguration
Returns:
the object to be searched.

setSearchString

public void setSearchString(
SystemSearchString string)
Description copied from interface: IHostSearchResultConfiguration
Sets the search string.

Specified by:
setSearchString in interface IHostSearchResultConfiguration
Parameters:
string - the search string.

getSearchString

public 
SystemSearchString getSearchString()
Description copied from interface: IHostSearchResultConfiguration
Gets the search string.

Specified by:
getSearchString in interface IHostSearchResultConfiguration
Returns:
string the search string.

addResult

public void addResult(
Object result)
Description copied from interface: IHostSearchResultConfiguration
Adds a search result.

Specified by:
addResult in interface IHostSearchResultConfiguration
Parameters:
result - a search result.

removeResult

public void removeResult(
Object result)
Description copied from interface: IHostSearchResultConfiguration
Removes a search result.

Specified by:
removeResult in interface IHostSearchResultConfiguration
Parameters:
result - a search result.

removeAndAddResult

public void removeAndAddResult(
Object oldResult,
                               
Object newResult)
Description copied from interface: IHostSearchResultConfiguration
Removes the old result and adds a new result.

Specified by:
removeAndAddResult in interface IHostSearchResultConfiguration
Parameters:
oldResult - the old result.
newResult - the new result.

getResults

public 
Object[] getResults()
Description copied from interface: IHostSearchResultConfiguration
Gets search results.

Specified by:
getResults in interface IHostSearchResultConfiguration
Returns:
search results.

getContainedResults

public 
IHostSearchResult[] getContainedResults(
Object resultContainer)
Description copied from interface: IHostSearchResultConfiguration
Gets the results contained within the resultContainer

Specified by:
getContainedResults in interface IHostSearchResultConfiguration
Returns:
the results

getResultsSize

public int getResultsSize()
Description copied from interface: IHostSearchResultConfiguration
Gets the size of the results.

Specified by:
getResultsSize in interface IHostSearchResultConfiguration
Returns:
the size of the results.

removeResults

public void removeResults()
Description copied from interface: IHostSearchResultConfiguration
Removes all search results.

Specified by:
removeResults in interface IHostSearchResultConfiguration

setStatus

public void setStatus(int status)
Description copied from interface: IHostSearchResultConfiguration
Sets the status of the search. One of RUNNING, FINISHED, CANCELLED, or DISCONNECTED.

Specified by:
setStatus in interface IHostSearchResultConfiguration
Parameters:
status - the status.

getStatus

public int getStatus()
Description copied from interface: IHostSearchResultConfiguration
Gets the status of the search. One of RUNNING, FINISHED, CANCELLED, or DISCONNECTED.

Specified by:
getStatus in interface IHostSearchResultConfiguration
Returns:
the status of the search.

cancel

public void cancel()
Description copied from interface: IHostSearchResultConfiguration
Cancels the search if it is running.

Specified by:
cancel in interface IHostSearchResultConfiguration

dispose

public void dispose()
Description copied from interface: IHostSearchResultConfiguration
Cancels the search and then removes the search results. Implementors should call super first.

Specified by:
dispose in interface IHostSearchResultConfiguration

addResults

public void addResults(
Object container,
                       
IHostSearchResult[] results)
Description copied from interface: IHostSearchResultConfiguration
Adds a set of search results along their associated container

Specified by:
addResults in interface IHostSearchResultConfiguration

setSearchHandler

public void setSearchHandler(
ISearchHandler searchHandler)
Description copied from interface: IHostSearchResultConfiguration
Sets the search handler

Specified by:
setSearchHandler in interface IHostSearchResultConfiguration

getSearchHandler

public 
ISearchHandler getSearchHandler()
Gets the search handler.

Returns:
the search handler.

RSE
Release 3.0

Copyright (c) IBM Corporation and others 2000, 2008. All Rights Reserved.

 
 
  Published under the terms of the Eclipse Public License Version 1.0 ("EPL") Design by Interspire