|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectprefuse.data.tuple.AbstractTupleSet
prefuse.data.tuple.DefaultTupleSet
prefuse.data.search.SearchTupleSet
prefuse.data.search.PrefixSearchTupleSet
public class PrefixSearchTupleSet
SearchTupleSet implementation supporting word prefix searches over indexed
Tuple data fields. This class uses a Trie data structure
to find search results quickly; however, only prefix matches will be
identified as valid search matches. Multi-term search queries will result
in the union of the results for the individual query terms. That is, Tuples
that match any one of the terms will be included in the results.
For more advanced search capabilities, see
KeywordSearchTupleSet or RegexSearchTupleSet.
SearchQueryBinding| Field Summary |
|---|
| Fields inherited from class prefuse.data.tuple.DefaultTupleSet |
|---|
m_tuples |
| Fields inherited from interface prefuse.data.event.EventConstants |
|---|
ALL_COLUMNS, DELETE, INSERT, UPDATE |
| Fields inherited from interface prefuse.data.tuple.TupleSet |
|---|
EMPTY_ARRAY |
| Constructor Summary | |
|---|---|
PrefixSearchTupleSet()
Creates a new KeywordSearchFocusSet that is not case sensitive. |
|
PrefixSearchTupleSet(boolean caseSensitive)
Creates a new KeywordSearchFocusSet with the indicated case sensitivity. |
|
| Method Summary | |
|---|---|
void |
clear()
Removes all search hits and clears out the index. |
java.lang.String |
getDelimiterString()
Returns the delimiter string used to divide data values and queries into separate words. |
java.lang.String |
getQuery()
Returns the current search query, if any. |
void |
index(Tuple t,
java.lang.String field)
Indexes the given field of the provided Tuple instance. |
boolean |
isUnindexSupported()
Returns true, as unidexing is supported by this class. |
void |
search(java.lang.String query)
Searches the indexed Tuple fields for matching string prefixes, adding the Tuple instances for each search match to this TupleSet. |
void |
setDelimiterString(java.lang.String delim)
Sets the delimiter string used to divide data values and queries into separate words. |
void |
unindex(Tuple t,
java.lang.String field)
Un-index an individual Tuple field, so that it can no longer be searched for. |
| Methods inherited from class prefuse.data.search.SearchTupleSet |
|---|
addTuple, index, removeTuple |
| Methods inherited from class prefuse.data.tuple.DefaultTupleSet |
|---|
addInternal, clearInternal, containsTuple, getTupleCount, removeInternal, setTuple, toArray, tuples |
| Methods inherited from class prefuse.data.tuple.AbstractTupleSet |
|---|
addColumn, addColumn, addColumn, addColumn, addColumns, addPropertyChangeListener, addPropertyChangeListener, addTupleSetListener, fireTupleEvent, fireTupleEvent, fireTupleEvent, getClientProperty, isAddColumnSupported, putClientProperty, removePropertyChangeListener, removePropertyChangeListener, removeTupleSetListener, tuples, tuples |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public PrefixSearchTupleSet()
public PrefixSearchTupleSet(boolean caseSensitive)
caseSensitive - true if the search routines should be case
sensitive, false otherwise.| Method Detail |
|---|
public java.lang.String getDelimiterString()
StringTokenizer instance that will tokenize the text.StringTokenizerpublic void setDelimiterString(java.lang.String delim)
delim - the delimiter string to use. This is passed as an argument
to a StringTokenizer instance that will tokenize the
text.StringTokenizerpublic java.lang.String getQuery()
SearchTupleSet
getQuery in class SearchTupleSetSearchTupleSet.getQuery()public void search(java.lang.String query)
search in class SearchTupleSetquery - the query string to search for.setDelimiterString(String)
public void index(Tuple t,
java.lang.String field)
index in class SearchTupleSett - the Tuplefield - the data field to indexSearchTupleSet.index(prefuse.data.Tuple, java.lang.String)public boolean isUnindexSupported()
isUnindexSupported in class SearchTupleSetSearchTupleSet.isUnindexSupported()
public void unindex(Tuple t,
java.lang.String field)
SearchTupleSet
unindex in class SearchTupleSett - the Tuplefield - the data field to unindexSearchTupleSet.unindex(prefuse.data.Tuple, java.lang.String)public void clear()
clear in interface TupleSetclear in class DefaultTupleSetTupleSet.clear()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||