Subversion Repositories HomeAutomation

Rev

Rev 15 | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | SVN | RSS feed

Rev 15 Rev 18
Line 5... Line 5...
5
 */
5
 */
6
package Macbeth.System;
6
package Macbeth.System;
7
 
7
 
8
import org.xml.sax.SAXException;
8
import org.xml.sax.SAXException;
9
 
9
 
-
 
10
import java.io.File;
10
import java.io.PrintStream;
11
import java.io.PrintStream;
11
import java.io.IOException;
12
import java.io.IOException;
12
import java.io.FileNotFoundException;
13
import java.io.FileNotFoundException;
13
import java.util.LinkedList;
14
import java.util.LinkedList;
14
import java.util.List;
15
import java.util.List;
Line 210... Line 211...
210
        }
211
        }
211
        //if there is a configuration data handler registered
212
        //if there is a configuration data handler registered
212
        if (configDataHandler!=null) {
213
        if (configDataHandler!=null) {
213
            //create XML parser and try to parse configuration file
214
            //create XML parser and try to parse configuration file
214
            XMLParser xmlParser = new XMLParser(configDataHandler);
215
            XMLParser xmlParser = new XMLParser(configDataHandler);
215
            configFile = "Config\\mod" + name() + ".xml";
216
            //configFile = "Config\\mod" + name() + ".xml";
-
 
217
            configFile = "Config"+File.separator+"mod" + name() + ".xml";
216
            try {
218
            try {
217
                xmlParser.parseFile(configFile);
219
                xmlParser.parseFile(configFile);
218
            } catch (FileNotFoundException e) {
220
            } catch (FileNotFoundException e) {
219
                //no config file existed. that's OK, but warn user
221
                //no config file existed. that's OK, but warn user
220
                // (a config data handler was registered after all)
222
                // (a config data handler was registered after all)