|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.townleyenterprises.io.AbstractLineProcessor com.townleyenterprises.io.DelimitedLineProcessor
This class provides the capability to break a line of delimited text into a list of objects representing each value.
Constructor Summary | |
DelimitedLineProcessor(java.lang.String delim)
The constructor initializes the processor with the delimiter to be used. |
Method Summary | |
abstract void |
processItems(java.util.List list)
This method gets called after the input line has been broken up into the individual tokens. |
void |
processLine(java.lang.String line)
This method gets called for each line processed containing the text of the line. |
void |
reset()
This method does nothing. |
Methods inherited from class com.townleyenterprises.io.AbstractLineProcessor |
getLineCount |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public DelimitedLineProcessor(java.lang.String delim)
delim
- the delimiterMethod Detail |
public void processLine(java.lang.String line) throws java.lang.Exception
processLine
in interface LineProcessor
processLine
in class AbstractLineProcessor
line
- the line of the input file
java.lang.Exception
- if an error occurs processing the linepublic abstract void processItems(java.util.List list) throws java.lang.Exception
list
- the list to process
java.lang.Exception
- if something goes wrong processing the itemspublic void reset()
reset
in interface LineProcessor
reset
in class AbstractLineProcessor
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |