se.datadosen.component
Class Autocompleter

java.lang.Object
  extended by se.datadosen.component.Autocompleter
All Implemented Interfaces:
java.util.EventListener, javax.swing.event.DocumentListener

public class Autocompleter
extends java.lang.Object
implements javax.swing.event.DocumentListener


Constructor Summary
Autocompleter(javax.swing.text.JTextComponent comp, WordList wordList)
           
 
Method Summary
 void changedUpdate(javax.swing.event.DocumentEvent ev)
           
 java.lang.String getPostfix()
          What to add after a word is completed
 java.lang.String getSeparatorChars()
           
 int getThreshold()
          Number of characters to type before an attempt is made to autocomplete
 WordList getWordList()
           
 void insertUpdate(javax.swing.event.DocumentEvent ev)
           
 void removeUpdate(javax.swing.event.DocumentEvent ev)
           
 void setPostfix(java.lang.String postfix)
          What to add after a word is completed
 void setSeparatorChars(java.lang.String separatorChars)
           
 void setThreshold(int threshold)
          Number of characters to type before an attempt is made to autocomplete
 void setWordList(WordList wordList)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Autocompleter

public Autocompleter(javax.swing.text.JTextComponent comp,
                     WordList wordList)
Method Detail

getPostfix

public java.lang.String getPostfix()
What to add after a word is completed

Parameters:
postfix -

setPostfix

public void setPostfix(java.lang.String postfix)
What to add after a word is completed

Parameters:
postfix -

getThreshold

public int getThreshold()
Number of characters to type before an attempt is made to autocomplete

Returns:

setThreshold

public void setThreshold(int threshold)
Number of characters to type before an attempt is made to autocomplete


getSeparatorChars

public java.lang.String getSeparatorChars()

setSeparatorChars

public void setSeparatorChars(java.lang.String separatorChars)

getWordList

public WordList getWordList()

setWordList

public void setWordList(WordList wordList)

changedUpdate

public void changedUpdate(javax.swing.event.DocumentEvent ev)
Specified by:
changedUpdate in interface javax.swing.event.DocumentListener

removeUpdate

public void removeUpdate(javax.swing.event.DocumentEvent ev)
Specified by:
removeUpdate in interface javax.swing.event.DocumentListener

insertUpdate

public void insertUpdate(javax.swing.event.DocumentEvent ev)
Specified by:
insertUpdate in interface javax.swing.event.DocumentListener