/** * ********************************************************************** * Create a <code>iniFile</code> object from the file named in the * parameter <code>fname</code>, and found on the parameter<code> path</code> * * @param path A <code>String</code> containing the path to the .ini file. * @param fname A <code>String</code> containing the name of the .ini file. * @param dbg A <code>boolean</code> that toggles debugging output. */ public iniFile(String path, String fname, boolean dbg) { Debug = dbg; if(path == null) path = System.getProperty("user.home"); String fileSeperator = System.getProperty("file.separator"); iniFile = path + fileSeperator + fname; errMsg = "The file: \"" + iniFile + "\" did not contain recognizable init information."; currentSection = -1; sectionNames = null; sectionProperties = null; parseFile(); if(sectionNames == null) System.err.println(errMsg); } //************************************************************************
/** * ********************************************************************** * Create a <code>iniFile</code> object from the file named in the * parameter <code>fname</code>, and found on the parameter<code> path</code> * * @param path A <code>String</code> containing the path to the .ini file. * @param fname A <code>String</code> containing the name of the .ini file. * @param dbg A <code>boolean</code> that toggles debugging output. */ public iniFile(String path, String fname, boolean dbg) { Debug = dbg; if (path == null) path = System.getProperty("user.home"); String fileSeperator = System.getProperty("file.separator"); iniFile = path + fileSeperator + fname; errMsg = "The file: \"" + iniFile + "\" did not contain recognizable init information."; currentSection = -1; sectionNames = null; sectionProperties = null; parseFile(); if (sectionNames == null) System.err.println(errMsg); } //************************************************************************