在com.install4j.runtime.launcher.WinLauncher.main获取异常(WinLauncher.java:26)

时间:2017-07-07 09:40:48

标签: install4j xerces

我使用Install4j创建了安装程序。我可以在windows和linux上安装带有这些安装程序的工具。

但是在Windows中,我正处于异常

之下
StartupHandler.initializeActionManager() ... ERROR: occurred while reading action shcema.
ERROR: SAX2 driver class org.apache.xerces.parsers.SAXParser does not implement XMLReader
org.xml.sax.SAXException: SAX2 driver class org.apache.xerces.parsers.SAXParser does not implement XMLReader
java.lang.ClassCastException: org.apache.xerces.parsers.XIncludeAwareParserConfiguration cannot be cast to org.apache.xerces.xni.parser.XMLParserConfiguration
    at org.xml.sax.helpers.XMLReaderFactory.loadClass(Unknown Source)
    at org.xml.sax.helpers.XMLReaderFactory.createXMLReader(Unknown Source)
    at com.appperfect.common.UtilityFunctions.parseXML(UtilityFunctions.java:1981)
    at com.appperfect.installer.common.ActionSchemaReader.loadActionConfigFile(ActionSchemaReader.java:74)
    at com.appperfect.installer.common.ActionSchemaReader.<init>(ActionSchemaReader.java:65)
    at com.appperfect.installer.common.ActionManager.loadActionSchema(ActionManager.java:157)
    at com.appperfect.installer.i4j.handlers.StartupHandler.initializeActionManager(StartupHandler.java:308)
    at com.appperfect.installer.i4j.handlers.StartupHandler.prepareInstaller(StartupHandler.java:86)
    at com.appperfect.installer.i4j.actions.AppStartupAction.install(AppStartupAction.java:43)
    at com.install4j.runtime.installer.ContextImpl$7.executeAction(ContextImpl.java:1668)
    at com.install4j.runtime.installer.ContextImpl$7.fetchValue(ContextImpl.java:1659)
    at com.install4j.runtime.installer.ContextImpl$7.fetchValue(ContextImpl.java:1656)
    at com.install4j.runtime.installer.helper.comm.actions.FetchObjectAction.execute(FetchObjectAction.java:14)
    at com.install4j.runtime.installer.helper.comm.HelperCommunication.executeActionDirect(HelperCommunication.java:274)
    at com.install4j.runtime.installer.helper.comm.HelperCommunication.executeActionInt(HelperCommunication.java:249)
    at com.install4j.runtime.installer.helper.comm.HelperCommunication.executeActionChecked(HelperCommunication.java:187)
    at com.install4j.runtime.installer.helper.comm.HelperCommunication.fetchObjectChecked(HelperCommunication.java:170)
    at com.install4j.runtime.installer.ContextImpl.performActionIntStatic(ContextImpl.java:1656)
    at com.install4j.runtime.installer.InstallerContextImpl.performActionInt(InstallerContextImpl.java:151)
    at com.install4j.runtime.installer.ContextImpl.performAction(ContextImpl.java:1103)
    at com.install4j.runtime.installer.controller.Controller.executeAction(Controller.java:368)
    at com.install4j.runtime.installer.controller.Controller.executeActions(Controller.java:334)
    at com.install4j.runtime.installer.controller.Controller.handleCommand(Controller.java:195)
    at com.install4j.runtime.installer.controller.Controller.handleStartup(Controller.java:116)
    at com.install4j.runtime.installer.controller.Controller.start(Controller.java:73)
    at com.install4j.runtime.installer.Installer.runInProcess(Installer.java:59)
    at com.install4j.runtime.installer.Installer.main(Installer.java:46)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
    at java.lang.reflect.Method.invoke(Unknown Source)
    at com.exe4j.runtime.LauncherEngine.launch(LauncherEngine.java:65)
    at com.exe4j.runtime.WinLauncher.main(WinLauncher.java:101)
    at com.install4j.runtime.launcher.WinLauncher.main(WinLauncher.java:26)
  • 我用google搜索,发现可能是由于xercesImpl.jar的版本不兼容,下载了最新的jar并试过但没有帮助。
  • 删除了xercseImpl.jar和xml-apis.jar,添加了xerces.jar。但问题仍然存在。

1 个答案:

答案 0 :(得分:1)

此问题已在install4j 6.1.6中修复。