我将自己写的一个项目打包成jar文件后在Eclipse中选择添加jar,将这个项目的jar包引入,然后使用这个jar包中的类,比如
SwapDepositInfo zw = new SwapDepositInfo();
此时Eclipse不会报任何错误,在我本地运行也通过,但是RCP发布后,在我的机器上可以显示正常,但是在其它部分的机器上,点发布后的程序后,就出现以上异常是怎么回事?(注:SWT工程)
java.lang.NoClassDefFoundError: cn/bestwiz/swt/xtable/beans/SwapDepositInfo
at cn.bestwiz.fes.front.comp.SwapDepositCompsite.initCompsite(SwapDepositCompsite.java:154)
at cn.bestwiz.fes.front.comp.BaseCompsite. <init> (BaseCompsite.java:24)
at cn.bestwiz.fes.front.comp.SwapDepositCompsite. <init> (SwapDepositCompsite.java:57)
at cn.bestwiz.fes.front.view.SwapDepositView.createPartControl(SwapDepositView.java:17)
at org.eclipse.ui.internal.ViewReference.createPartHelper(ViewReference.java:332)
at org.eclipse.ui.internal.ViewReference.createPart(ViewReference.java:197)
at org.eclipse.ui.internal.WorkbenchPartReference.getPart(WorkbenchPartReference.java:566)
at org.eclipse.ui.internal.PartPane.setVisible(PartPane.java:290)
at org.eclipse.ui.internal.ViewPane.setVisible(ViewPane.java:525)
at org.eclipse.ui.internal.presentations.PresentablePart.setVisible(PresentablePart.java:140)
at org.eclipse.ui.internal.presentations.util.PresentablePartFolder.select(PresentablePartFolder.java:268)
at org.eclipse.ui.internal.presentations.util.LeftToRightTabOrder.select(LeftToRightTabOrder.java:65)
at org.eclipse.ui.internal.presentations.util.TabbedStackPresentation.selectPart(TabbedStackPresentation.java:394)
at org.eclipse.ui.internal.PartStack.refreshPresentationSelection(PartStack.java:1144)
at org.eclipse.ui.internal.PartStack.setSelection(PartStack.java:1097)
at org.eclipse.ui.internal.PartStack.presentationSelectionChanged(PartStack.java:795)
at org.eclipse.ui.internal.PartStack.access$1(PartStack.java:781)
at org.eclipse.ui.internal.PartStack$1.selectPart(PartStack.java:123)
at org.eclipse.ui.internal.presentations.util.TabbedStackPresentation$1.handleEvent(TabbedStackPresentation.java:126)
at org.eclipse.ui.internal.presentations.util.AbstractTabFolder.fireEvent(AbstractTabFolder.java:267)
at org.eclipse.ui.internal.presentations.util.AbstractTabFolder.fireEvent(AbstractTabFolder.java:276)
at org.eclipse.ui.internal.presentations.defaultpresentation.DefaultTabFolder.access$1(DefaultTabFolder.java:1)
at org.eclipse.ui.internal.presentations.defaultpresentation.DefaultTabFolder$2.handleEvent(DefaultTabFolder.java:84)
at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:66)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:928)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:952)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:937)
at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java:709)
at org.eclipse.swt.custom.CTabFolder.setSelection(CTabFolder.java:3171)
at org.eclipse.swt.custom.CTabFolder.onMouse(CTabFolder.java:1953)
at org.eclipse.swt.custom.CTabFolder$1.handleEvent(CTabFolder.java:288)
at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:66)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:928)
at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:3348)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:2968)
at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:1930)