0
我有一個相當艱難的時間,試圖利用interprolog的Java/Prolog的幫助 - 故障排除
我有一些代碼,試圖調用一個序言命令,問題是我的序言數據庫的實際負荷。下面是代碼:
myEngine = new NativeEngine();
myEngine.consultFromPackage("userlist.p", LoginHandler.class);
boolean x = myEngine.deterministicGoal("has_access(user,pass)");
當我運行程序序言初始化精細,它會嘗試尋找userlist.p這是在同一個包(的代碼第二行),然後它將引發此錯誤:
Exception in thread "AWT-EventQueue-0" com.declarativa.interprolog.util.IPException: Problem consulting from package archive:C:\Users\Keval\AppData\Local\Temp\IP_6971701367857416872\userlist.p
at com.declarativa.interprolog.AbstractPrologEngine.consultFromPackage(AbstractPrologEngine.java)
at handlers.LoginHandler.actionPerformed(LoginHandler.java:25)
at javax.swing.AbstractButton.fireActionPerformed(Unknown Source)
at javax.swing.AbstractButton$Handler.actionPerformed(Unknown Source)
at javax.swing.DefaultButtonModel.fireActionPerformed(Unknown Source)
at javax.swing.DefaultButtonModel.setPressed(Unknown Source)
at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(Unknown Source)
at java.awt.Component.processMouseEvent(Unknown Source)
at javax.swing.JComponent.processMouseEvent(Unknown Source)
at java.awt.Component.processEvent(Unknown Source)
at java.awt.Container.processEvent(Unknown Source)
at java.awt.Component.dispatchEventImpl(Unknown Source)
at java.awt.Container.dispatchEventImpl(Unknown Source)
at java.awt.Component.dispatchEvent(Unknown Source)
at java.awt.LightweightDispatcher.retargetMouseEvent(Unknown Source)
at java.awt.LightweightDispatcher.processMouseEvent(Unknown Source)
at java.awt.LightweightDispatcher.dispatchEvent(Unknown Source)
at java.awt.Container.dispatchEventImpl(Unknown Source)
at java.awt.Window.dispatchEventImpl(Unknown Source)
at java.awt.Component.dispatchEvent(Unknown Source)
at java.awt.EventQueue.dispatchEvent(Unknown Source)
at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.run(Unknown Source)
我看着爲consultFromPackage代碼:
public void consultFromPackage(String filename,Object requester){
String path = cleanPath(copyToTemp(filename,requester).getPath());
path = unescapedFilePath(path);
progressMessage("consultFromPackage:"+path);
if (!command("consult('"+path+"')"))
throw new IPException("Problem consulting from package archive:"+path);
}
,但我似乎無法得到的problem..i根知道這是所有有點遠,但任何幫助讚賞在這一點上。
感謝
人?任何想法讚賞。 – KP65 2010-02-13 16:42:50