Package com.aquima.interactions.dtree
Interface ISearchResult
-
- All Superinterfaces:
Serializable
- All Known Implementing Classes:
SearchResult
public interface ISearchResult extends Serializable
This interface is the result of a search action on a tree engine. It holds the decisiontrees and their scores which matched the best.- Since:
- 5.1
- Author:
- F. van der Meer.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description ISearchEntry
getMatchAt(int pos)
Returns the matching entry at the designated position.int
getMatchCount()
Returns the number of matches the result contains.ISearchEntry[]
getMatches()
This function returns an ordered array of matching entries.String
getQuery()
The query passed to the tree engine as search action.
-
-
-
Method Detail
-
getQuery
String getQuery()
The query passed to the tree engine as search action.- Returns:
- String holding the search string.
-
getMatchCount
int getMatchCount()
Returns the number of matches the result contains.- Returns:
- a number larger then 0.
-
getMatchAt
ISearchEntry getMatchAt(int pos) throws IllegalArgumentException
Returns the matching entry at the designated position.- Parameters:
pos
- position ranging from 0 to matchcount.- Returns:
- a search entry, which is never null
- Throws:
IllegalArgumentException
- when the index is out of range.
-
getMatches
ISearchEntry[] getMatches()
This function returns an ordered array of matching entries. Position 0 (if any) will contain the best match for the search set.- Returns:
- an array of ISearchEntry object. It returns never null but can be zero length.
-
-