Skip to main content
Package: com.phoenix_int.aserver.util Class Hierarchy

Declaration
This is a utility class for loading data files. The class makes it easy to load files, line by line while ignoring comments (lines that begin with #). Sample Usage:

Constructor Summary

Method Summary

Methods inherited from class java.lang.Object

clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Constructor Detail

PHXFileLoader

Parameters:
  • fileName - the file to load Throws:
  • java.io.IOException - if there is a problem opening the file

PHXFileLoader

Parameters:
  • file - the file to load
Throws:
  • java.io.IOException - if there is a problem opening the file

PHXFileLoader

Throws:
  • java.io.IOException

PHXFileLoader

Throws:
  • java.io.IOException

Method Detail

finalize

Overrides:
  • finalize in class java.lang.Object

close

closes the file

getFileName

retrieves the file name Returns:
  • the name of the file

getLineNumber

returns the line number of the last line read. Indexing starts at 1 Returns:
  • the last line number

nextLine

extracts the next non-comment line from the data file Returns:
  • a non-comment line

readNextLine

extracts the next line from the data file Returns:
  • a line

getRemainder

returns the rest of the file as a string Returns:
  • the remaining contents of the file