Remote Systems
v6.4.1

com.ibm.etools.systems.subsystems
Interface IRemoteSearchResult

All Superinterfaces:
IRemoteLineReference
All Known Implementing Classes:
RemoteSearchResultImpl

public interface IRemoteSearchResult
extends IRemoteLineReference

This interface represents a handle to a search result.


Field Summary
static String Copyright
           
static String SEARCH_RESULT_CLOSE_DELIMITER
           
static String SEARCH_RESULT_DELIMITER
           
static String SEARCH_RESULT_INDEX_DELIMITER
           
static String SEARCH_RESULT_OPEN_DELIMITER
           
 
Method Summary
 void addMatch(int startOffset, int endOffset)
          Add a match to the result.
 int getCharEnd(int matchIndex)
          Gets the char end offset for the given match index.
 int getCharStart(int matchIndex)
          Gets the char start offset for the given match index.
 int getIndex()
          Gets the index of this search result in the context of its parent.
 SystemSearchString getMatchingSearchString()
          Gets the search string that this result matches.
 String getText()
          Gets the text to display for a search result.
 int numOfMatches()
          Gets the number of matches in this line.
 
Methods inherited from interface com.ibm.etools.systems.subsystems.IRemoteLineReference
getAbsolutePath, getCharEnd, getCharStart, getLine, getParent
 

Field Detail

Copyright

public static final String Copyright
See Also:
Constant Field Values

SEARCH_RESULT_DELIMITER

public static final String SEARCH_RESULT_DELIMITER
See Also:
Constant Field Values

SEARCH_RESULT_OPEN_DELIMITER

public static final String SEARCH_RESULT_OPEN_DELIMITER
See Also:
Constant Field Values

SEARCH_RESULT_CLOSE_DELIMITER

public static final String SEARCH_RESULT_CLOSE_DELIMITER
See Also:
Constant Field Values

SEARCH_RESULT_INDEX_DELIMITER

public static final String SEARCH_RESULT_INDEX_DELIMITER
See Also:
Constant Field Values
Method Detail

getText

public String getText()
Gets the text to display for a search result.

Returns:
the text.

getIndex

public int getIndex()
Gets the index of this search result in the context of its parent.

Returns:
the index.

getMatchingSearchString

public SystemSearchString getMatchingSearchString()
Gets the search string that this result matches.

Returns:
the search string.

addMatch

public void addMatch(int startOffset,
                     int endOffset)
Add a match to the result. A match comprises a char start offset and a char end offset, both relative to the beginning of the file. The matches are added in order.

Parameters:
startOffset - the char start offset, from the beginning of the file.
endOffset - the char end offset, from the beginning of the file.

numOfMatches

public int numOfMatches()
Gets the number of matches in this line.

Returns:
the number of matches.

getCharStart

public int getCharStart(int matchIndex)
Gets the char start offset for the given match index.

Parameters:
matchIndex - the match index. For example, to get the start offset for the first match, specify 0.
Returns:
the char start offset.

getCharEnd

public int getCharEnd(int matchIndex)
Gets the char end offset for the given match index.

Parameters:
matchIndex - the match index. For example, to get the end offset for the first match, specify 0.
Returns:
the char end offset.

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.