ghm.follow.search
Class LineResult

java.lang.Object
  extended by ghm.follow.search.LineResult

public class LineResult
extends java.lang.Object

Keeps results information about a line in the searchable text.

Author:
Carl Hall (carl.hall@gmail.com)

Field Summary
 int end
           
 int lineNumber
           
 int start
           
 
Constructor Summary
LineResult(int lineNumber, int start, int end)
          Constructor
 
Method Summary
 void addWord(WordResult wordResult)
          Add a WordResult to this line
 int getFirstWordPosition()
          Get the caret position of the first occurring word result on this line.
 WordResult getWordResult(int index)
          Get a specific word result associated with this line.
 java.util.List<WordResult> getWordResults()
          Get the word results associated with this line.
 java.lang.String toString()
          Builds a string that is conducive for showing as a result list entry
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

lineNumber

public int lineNumber

start

public int start

end

public int end
Constructor Detail

LineResult

public LineResult(int lineNumber,
                  int start,
                  int end)
Constructor

Parameters:
lineNumber -
Method Detail

getWordResults

public java.util.List<WordResult> getWordResults()
Get the word results associated with this line.

Returns:

getWordResult

public WordResult getWordResult(int index)
Get a specific word result associated with this line.

Parameters:
index -
Returns:

getFirstWordPosition

public int getFirstWordPosition()
Get the caret position of the first occurring word result on this line.

Returns:

addWord

public void addWord(WordResult wordResult)
Add a WordResult to this line

Parameters:
wordResult -

toString

public java.lang.String toString()
Builds a string that is conducive for showing as a result list entry

Overrides:
toString in class java.lang.Object


Copyright © 2008. All Rights Reserved.