Remote Systems
v6.4.1

com.ibm.etools.systems.subsystems.impl
Class RemoteSearchResultConfigurationImpl

java.lang.Object
  extended bycom.ibm.etools.systems.subsystems.impl.RemoteSearchResultConfigurationImpl
All Implemented Interfaces:
IRemoteSearchConstants, IRemoteSearchResultConfiguration
Direct Known Subclasses:
LocalSearchResultConfigurationImpl, UniversalSearchResultConfigurationImpl

public class RemoteSearchResultConfigurationImpl
extends Object
implements IRemoteSearchResultConfiguration

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  IRemoteSearchResultSet parentResultSet
           
protected  Vector results
           
protected  SystemSearchString searchString
           
protected  Object searchTarget
           
protected  int status
           
 
Fields inherited from interface com.ibm.etools.systems.subsystems.IRemoteSearchConstants
CANCELLED, DISCONNECTED, FINISHED, RUNNING
 
Constructor Summary
RemoteSearchResultConfigurationImpl(IRemoteSearchResultSet resultSet, Object searchObject, SystemSearchString string)
          Constructor for a result set configuration.
 
Method Summary
 void addResult(Object result)
          Adds a search result.
 void cancel()
          Does nothing.
 void dispose()
          Cancels the search and then removes the search results.
 IRemoteSearchResultSet getParentResultSet()
          Gets the parent result set.
 Object[] getResults()
          Gets search results.
 int getResultsSize()
          Gets the size of the results.
 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(IRemoteSearchResultSet resultSet)
          Sets the parent result set.
 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 IRemoteSearchResultSet parentResultSet

searchTarget

protected Object searchTarget

searchString

protected SystemSearchString searchString

results

protected Vector results

status

protected int status
Constructor Detail

RemoteSearchResultConfigurationImpl

public RemoteSearchResultConfigurationImpl(IRemoteSearchResultSet resultSet,
                                           Object searchObject,
                                           SystemSearchString string)
Constructor for a result set configuration. Sets status to RUNNING.

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

setParentResultSet

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

Specified by:
setParentResultSet in interface IRemoteSearchResultConfiguration
Parameters:
resultSet - the parent result set.
See Also:
IRemoteSearchResultConfiguration.setParentResultSet(com.ibm.etools.systems.subsystems.IRemoteSearchResultSet)

getParentResultSet

public IRemoteSearchResultSet getParentResultSet()
Description copied from interface: IRemoteSearchResultConfiguration
Gets the parent result set.

Specified by:
getParentResultSet in interface IRemoteSearchResultConfiguration
Returns:
the parent result set.
See Also:
IRemoteSearchResultConfiguration.getParentResultSet()

setSearchTarget

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

Specified by:
setSearchTarget in interface IRemoteSearchResultConfiguration
Parameters:
searchObject - the object to be searched.
See Also:
IRemoteSearchResultConfiguration.setSearchTarget(java.lang.Object)

getSearchTarget

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

Specified by:
getSearchTarget in interface IRemoteSearchResultConfiguration
Returns:
the object to be searched.
See Also:
IRemoteSearchResultConfiguration.getSearchTarget()

setSearchString

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

Specified by:
setSearchString in interface IRemoteSearchResultConfiguration
Parameters:
string - the search string.
See Also:
IRemoteSearchResultConfiguration.setSearchString(com.ibm.etools.systems.core.clientserver.SystemSearchString)

getSearchString

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

Specified by:
getSearchString in interface IRemoteSearchResultConfiguration
Returns:
string the search string.
See Also:
IRemoteSearchResultConfiguration.getSearchString()

addResult

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

Specified by:
addResult in interface IRemoteSearchResultConfiguration
Parameters:
result - a search result.
See Also:
IRemoteSearchResultConfiguration.addResult(java.lang.Object)

removeResult

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

Specified by:
removeResult in interface IRemoteSearchResultConfiguration
Parameters:
result - a search result.
See Also:
IRemoteSearchResultConfiguration.removeResult(java.lang.Object)

removeAndAddResult

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

Specified by:
removeAndAddResult in interface IRemoteSearchResultConfiguration
Parameters:
oldResult - the old result.
newResult - the new result.
See Also:
IRemoteSearchResultConfiguration.removeAndAddResult(java.lang.Object, java.lang.Object)

getResults

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

Specified by:
getResults in interface IRemoteSearchResultConfiguration
Returns:
search results.
See Also:
IRemoteSearchResultConfiguration.getResults()

getResultsSize

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

Specified by:
getResultsSize in interface IRemoteSearchResultConfiguration
Returns:
the size of the results.
See Also:
IRemoteSearchResultConfiguration.getResultsSize()

removeResults

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

Specified by:
removeResults in interface IRemoteSearchResultConfiguration
See Also:
IRemoteSearchResultConfiguration.removeResults()

setStatus

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

Specified by:
setStatus in interface IRemoteSearchResultConfiguration
See Also:
IRemoteSearchResultConfiguration.setStatus(int)

getStatus

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

Specified by:
getStatus in interface IRemoteSearchResultConfiguration
Returns:
the status of the search.
See Also:
IRemoteSearchResultConfiguration.getStatus()

cancel

public void cancel()
Does nothing.

Specified by:
cancel in interface IRemoteSearchResultConfiguration
See Also:
IRemoteSearchResultConfiguration.cancel()

dispose

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

Specified by:
dispose in interface IRemoteSearchResultConfiguration
See Also:
IRemoteSearchResultConfiguration.dispose()

Remote Systems
v6.4.1

Copyright © 2005 IBM Corp. All Rights Reserved.

Note: This documentation is for part of an interim API that is still under development and expected to change significantly before reaching stability. It is being made available at this early stage to solicit feedback from pioneering adopters on the understanding that any code that uses this API will almost certainly be broken (repeatedly) as the API evolves.