kylm.reader
Class TextFileClassMapReader

java.lang.Object
  extended by kylm.reader.TextStreamClassMapReader
      extended by kylm.reader.TextFileClassMapReader
All Implemented Interfaces:
ClassMapReader

public class TextFileClassMapReader
extends TextStreamClassMapReader


Constructor Summary
TextFileClassMapReader(java.lang.String fileName)
          The constructor, saves the file and uses a single space as the default divider
TextFileClassMapReader(java.lang.String fileName, java.lang.String divider)
          The constructor, saves the file name and uses the passed in divider
 
Method Summary
 ClassMap readClassMap(SymbolSet ss, int fixed, boolean hasNames)
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TextFileClassMapReader

public TextFileClassMapReader(java.lang.String fileName)
                       throws java.io.IOException
The constructor, saves the file and uses a single space as the default divider

Parameters:
fileName - The name of the file to be opened
Throws:
java.io.IOException - if the file doesn't exist or is unreadable

TextFileClassMapReader

public TextFileClassMapReader(java.lang.String fileName,
                              java.lang.String divider)
                       throws java.io.IOException
The constructor, saves the file name and uses the passed in divider

Parameters:
fileName - The name of the file to be opened
divider - A regular expression that is used to divide strings in the corpus
Throws:
java.io.IOException - if the file doesn't exist or is unreadable
Method Detail

readClassMap

public ClassMap readClassMap(SymbolSet ss,
                             int fixed,
                             boolean hasNames)
                      throws java.io.IOException
Specified by:
readClassMap in interface ClassMapReader
Overrides:
readClassMap in class TextStreamClassMapReader
Throws:
java.io.IOException