ruper2/src/java/core/org/krysalis/ruper/config RuperConfig.java,1.1,1.2
| Newsgroups | gmane.comp.krysalis.metamorphosis.cvs |
|---|---|
| Message-ID | <[email protected]> |
Update of /cvsroot/metamorphosis/ruper2/src/java/core/org/krysalis/ruper/config
In directory sc8-pr-cvs1:/tmp/cvs-serv24844/src/java/core/org/krysalis/ruper/config
Modified Files:
RuperConfig.java
Log Message:
Tried getting ruper.xml to parse, and failed.
Index: RuperConfig.java
===================================================================
RCS file: /cvsroot/metamorphosis/ruper2/src/java/core/org/krysalis/ruper/config/RuperConfig.java,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** RuperConfig.java 9 Sep 2003 20:54:40 -0000 1.1
--- RuperConfig.java 9 Sep 2003 21:49:06 -0000 1.2
***************
*** 6,10 ****
--- 6,13 ----
import java.io.File;
+ import org.krysalis.ruper.impl.ReferenceManager;
+ import org.krysalis.ruper.log.Logger;
import org.krysalis.ruper.util.RuperConstants;
+ import org.krysalis.ruper.util.text.Messages;
import org.krysalis.ruper.util.xml.XMLContext;
import org.krysalis.ruper.util.xml.XMLEntryTable;
***************
*** 14,43 ****
* @author anou_mana
*/
! public class RuperConfig
! {
! public static void configure(String configFileName)
! {
! try
! {
File configFile = new File(configFileName);
!
XMLEntryTable xmlEntryTable = new XMLEntryTable();
!
XMLParser parser = new XMLParser(xmlEntryTable);
! XMLContext xmlContext = parser.parse(configFile);
}
- catch(Exception exp)
- {
- }
}
!
! public static void configure()
! {
! configure(RuperConstants.DEFAULT_CONFIG_XML);
}
!
! public static void main(String[] args)
! {
}
}
--- 17,51 ----
* @author anou_mana
*/
! public class RuperConfig {
! private static boolean l_configured = false;
! public static void configure(String configFileName) {
! try {
File configFile = new File(configFileName);
!
XMLEntryTable xmlEntryTable = new XMLEntryTable();
!
XMLParser parser = new XMLParser(xmlEntryTable);
! XMLContext xmlContext = parser.parse(configFile);
! }
! catch (Exception exp) {
! Logger.getLog().error(Messages.getString("CONFIG_ERROR"), exp);
}
}
!
! public static void configure() {
! if (!l_configured)
! {
! configure(RuperConstants.DEFAULT_CONFIG_XML);
!
! l_configured = true;
! }
}
!
! public static void main(String[] args) {
!
! RuperConfig.configure();
!
! ReferenceManager.dump();
}
}
-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf