|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.pz.platypus.Infile
public class Infile
Handles input file I/O functions.
Field Summary | |
---|---|
private int |
currFileNumber
the current line number and filenumber |
private int |
currLineNumber
|
private java.lang.String |
filename
the name of the input file |
private GDD |
gdd
the GDD |
private java.io.BufferedReader |
inReader
input reader for file |
private boolean |
isOpen
file open status |
Constructor Summary | |
---|---|
Infile(java.lang.String name,
GDD Gdd)
|
Method Summary | |
---|---|
java.lang.String |
getFilename()
|
int |
getLineNumber()
|
int |
open()
open the file |
int |
readFileIntoInputLines(LineList textLines)
Reads the input file on a line basis, adding each line to an ArrayList for later processing. |
private int |
readNext1LineIntoInputLine(InputLine inputLine)
Reads a single line from the input file and converts into an InputLine data structure, which contains, the file number of the input file, the line number of the line, plus the content of the line |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
private final java.lang.String filename
private boolean isOpen
private java.io.BufferedReader inReader
private int currFileNumber
private int currLineNumber
private GDD gdd
Constructor Detail |
---|
public Infile(java.lang.String name, GDD Gdd)
Method Detail |
---|
public int readFileIntoInputLines(LineList textLines)
textLines
- array of InputLine's into which the file will be read.
private int readNext1LineIntoInputLine(InputLine inputLine)
inputLine
- the InputLine into which the line of content is placed
public int open()
public java.lang.String getFilename()
public int getLineNumber()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |