public class PlainTextDictionary extends java.lang.Object implements Dictionary
Format allowed: 1 word per line:
word1
word2
word3
Modifier and Type | Class and Description |
---|---|
(package private) class |
PlainTextDictionary.FileIterator |
Modifier and Type | Field and Description |
---|---|
private java.io.BufferedReader |
in |
Constructor and Description |
---|
PlainTextDictionary(java.io.InputStream dictFile)
Creates a dictionary based on an inputstream.
|
PlainTextDictionary(java.nio.file.Path path)
Creates a dictionary based on a Path.
|
PlainTextDictionary(java.io.Reader reader)
Creates a dictionary based on a reader.
|
Modifier and Type | Method and Description |
---|---|
InputIterator |
getEntryIterator()
Returns an iterator over all the entries
|
public PlainTextDictionary(java.nio.file.Path path) throws java.io.IOException
NOTE: content is treated as UTF-8
java.io.IOException
public PlainTextDictionary(java.io.InputStream dictFile)
NOTE: content is treated as UTF-8
public PlainTextDictionary(java.io.Reader reader)
public InputIterator getEntryIterator() throws java.io.IOException
Dictionary
getEntryIterator
in interface Dictionary
java.io.IOException