我已经在 STS 3.3.0(Juno 3.8.2 版本)以及 m2e wtp 连接器中安装了 Websphere 开发工具。我现在在构建 Maven 时遇到问题。使用 maven 更新项目时出现以下异常。
java.lang.NoClassDefFoundError: org.eclipse.m2e.wtp.WTPProjectsUtil
at com.ibm.etools.maven.javaee.core.configurators.Utils.isJPAProject(Utils.java:43)
at com.ibm.etools.maven.javaee.core.configurators.JPAProjectConfiguratorDelegate.configureProject(JPAProjectConfiguratorDelegate.java:46)
at com.ibm.etools.maven.javaee.core.configurators.JPAProjectConfigurator.configure(JPAProjectConfigurator.java:45)
at org.eclipse.m2e.core.project.configurator.AbstractLifecycleMapping.configure(AbstractLifecycleMapping.java:109)
at org.eclipse.m2e.core.internal.project.ProjectConfigurationManager$3.call(ProjectConfigurationManager.java:472)
at org.eclipse.m2e.core.internal.project.ProjectConfigurationManager$3.call(ProjectConfigurationManager.java:1)
at org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.executeBare(MavenExecutionContext.java:161)
at org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:137)
at org.eclipse.m2e.core.internal.project.ProjectConfigurationManager.updateProjectConfiguration(ProjectConfigurationManager.java:465)
at org.eclipse.m2e.core.internal.project.ProjectConfigurationManager.updateProjectConfiguration0(ProjectConfigurationManager.java:403)
at org.eclipse.m2e.core.internal.project.ProjectConfigurationManager$2.call(ProjectConfigurationManager.java:316)
at org.eclipse.m2e.core.internal.project.ProjectConfigurationManager$2.call(ProjectConfigurationManager.java:1)
at org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.executeBare(MavenExecutionContext.java:161)
at org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:137)
at org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:89)
at org.eclipse.m2e.core.internal.embedder.MavenImpl.execute(MavenImpl.java:1301)
at org.eclipse.m2e.core.internal.project.ProjectConfigurationManager.updateProjectConfiguration(ProjectConfigurationManager.java:313)
at org.eclipse.m2e.core.ui.internal.UpdateMavenProjectJob.runInWorkspace(UpdateMavenProjectJob.java:77)
at org.eclipse.core.internal.resources.InternalWorkspaceJob.run(InternalWorkspaceJob.java:38)
at org.eclipse.core.internal.jobs.Worker.run(Worker.java:54)
但是,当我查看插件目录时,我可以看到包含相关类的 jar 文件 org.eclipse.m2e.wtp_1.0.0.20130613-0136.jar。我如何计算出 eclipse 类路径是什么,有没有办法将此库添加到类路径中?