|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.lucene.search.suggest.FileDictionary
public class FileDictionary
Dictionary represented by a text file.
Format allowed: 1 entry per line:fieldDelimiter
weightfieldDelimiter
weight fieldDelimiter
payloadfieldDelimiter
is "\t"fieldDelimiter
Field Summary | |
---|---|
static String |
DEFAULT_FIELD_DELIMITER
Tab-delimited fields are most common thus the default, but one can override this via the constructor |
Constructor Summary | |
---|---|
FileDictionary(InputStream dictFile)
Creates a dictionary based on an inputstream. |
|
FileDictionary(InputStream dictFile,
String fieldDelimiter)
Creates a dictionary based on an inputstream. |
|
FileDictionary(Reader reader)
Creates a dictionary based on a reader. |
|
FileDictionary(Reader reader,
String fieldDelimiter)
Creates a dictionary based on a reader. |
Method Summary | |
---|---|
InputIterator |
getEntryIterator()
Returns an iterator over all the entries |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final String DEFAULT_FIELD_DELIMITER
Constructor Detail |
---|
public FileDictionary(InputStream dictFile)
DEFAULT_FIELD_DELIMITER
as the
field seperator in a line.
NOTE: content is treated as UTF-8
public FileDictionary(Reader reader)
DEFAULT_FIELD_DELIMITER
as the
field seperator in a line.
public FileDictionary(Reader reader, String fieldDelimiter)
fieldDelimiter
to seperate out the
fields in a line.
public FileDictionary(InputStream dictFile, String fieldDelimiter)
fieldDelimiter
to seperate out the
fields in a line.
NOTE: content is treated as UTF-8
Method Detail |
---|
public InputIterator getEntryIterator()
Dictionary
getEntryIterator
in interface Dictionary
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |