edu.northwestern.at.wordhoard.model.search
Class SearchResult

java.lang.Object
  extended by edu.northwestern.at.wordhoard.model.search.SearchResult

public class SearchResult
extends java.lang.Object

A search result.

A search result is a word and the index in the word of a word part.

The index of the word part is -1 if the search did not include a lemma, part of speech, word class, or major word class criteron. In this case, no particular part of the word is responsible for the word being a result (as in, for exammple, a search by spelling only).


Constructor Summary
SearchResult(Word word, int partIndex)
          Creates a new search result.
 
Method Summary
 int getPartIndex()
          Gets the part index in the word.
 Word getWord()
          Gets the word.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SearchResult

public SearchResult(Word word,
                    int partIndex)
Creates a new search result.

Parameters:
word - The word.
partIndex - The part index in the word, or -1 if none.
Method Detail

getWord

public Word getWord()
Gets the word.

Returns:
The word.

getPartIndex

public int getPartIndex()
Gets the part index in the word.

Returns:
The part index in the word, or -1 if none.