public void search(String query){
  if (query == null)   query="";
  if (query.equals(m_query))   return;
  Tuple[] rem=clearInternal();
  m_query=query;
  StringTokenizer st=new StringTokenizer(m_query,m_delim);
  if (!st.hasMoreTokens())   m_query="";
  while (st.hasMoreTokens())   prefixSearch(st.nextToken());
  Tuple[] add=getTupleCount() > 0 ? toArray() : null;
  fireTupleEvent(add,rem);
}

public void search ( String query ) { if ( query == null ) query = "" ; if ( query . equals ( m_query ) ) return ; Tuple [ ] rem = clearInternal ( ) ; m_query = query ; StringTokenizer st = new StringTokenizer ( m_query , m_delim ) ; if ( ! st . hasMoreTokens ( ) ) m_query = "" ; while ( st . hasMoreTokens ( ) ) prefixSearch ( st . nextToken ( ) ) ; Tuple [ ] add = getTupleCount ( ) > 0 ? toArray ( ) : null ; fireTupleEvent ( add , rem ) ; }
searches the indexed tuple fields for matching string prefixes , adding the tuple instances for each search match to this tupleset . the query string is first broken up into separate terms , as determined by the current delimiter string . a search for each term is conducted , and all matching tuples are included in the results .
