// This lets the property be specified as a file name
// even if it's not specified as file:/<name> in
// the properties file.
URL csvURL = infoUrl;
streamReader = new BufferedReader(new InputStreamReader(csvURL.openStream()));
CSVTokenizer csvt = new CSVTokenizer(streamReader, readNumbersAsStrings);
int count = 0;
token = csvt.token();
while (!csvt.isEOF(token)) {
count++;
Vector rec_line = new Vector();
while (!csvt.isNewline(token)) {
rec_line.addElement(token);
token = csvt.token();
if (csvt.isEOF(token))
break;
}
// Don't add the header record, because we don't care
// about it.
if (header_read) {
records.addElement(rec_line);
} else if (headersExist) {
headerRecord = rec_line;
header_read = true;
}
if (Debug.debugging("csv")) {
Debug.output("CSVFile.read: " + rec_line);
}
token = csvt.token();
}
} catch (java.io.IOException ioe) {
throw new com.bbn.openmap.util.HandleError(ioe);
} catch (ArrayIndexOutOfBoundsException aioobe) {
throw new com.bbn.openmap.util.HandleError(aioobe);