日食 + GWT 类路径错误
我正在将 Eclipse 与 GWT 结合使用,并尝试构建一个基于 Web 的应用程序。我是初学者,不知道这意味着什么。我试图在网上查找但没有令人满意的解释。我只能弄清楚我需要编辑一些文件,但我不知道如何编辑。任何帮助表示赞赏。
加载模块 com.model.WebCrawler.WebCrawler
[错误] 无法在类路径上找到“com/model/WebCrawler/WebCrawler.gwt.xml”;可能是拼写错误,或者您忘记添加 源的类路径条目?
[错误] shell 在 doStartup 方法中失败
I am using Eclipse with GWT and trying to build a Web based application. I am a beginner and have no idea what this means. I tried to look in the web but no satisfactory explanation. I can only figure out that I need to edit some file, but I don't know how. Any help appreciated.
Loading modules com.model.WebCrawler.WebCrawler
[ERROR] Unable to find 'com/model/WebCrawler/WebCrawler.gwt.xml' on your classpath; could be a typo, or maybe you forgot to include a
classpath entry for source?
[ERROR] shell failed in doStartup method
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
您需要一个模块 XML 文件才能正确加载应用程序。
查看 Google 教程并搜索模块 XML 文件。
如果您使用 eclipse 的 gwt 插件,您可以创建一个示例项目,其中将为您生成最困难的部分,以便您几乎可以立即开始使用您的自定义代码。
You need a module XML file for your application to load correctly.
Take a look at the google tutorials and search for module XML file.
If you use the gwt plugin for eclipse, you can create a sample project where the most struggling parts will be generated for you, so that you can pretty much start immediatly with your custom code.
您可以做的是使用 eclipse(和 GWT 插件)创建一个基本的 GWT 项目,并选中复选框以包含源代码。这样您就可以了解如何设置文件并有一个可供查看的工作示例。
如果您是从头开始,那么是的,您需要命名模块 xml 文件以匹配您的项目。这是 GWT 约定。
What you could do is create a basic GWT project with eclipse (and the GWT plugin) and check the checkbox to include the source. That way you can look at how the files should be setup and have a working example to review.
If you are doing it from scratch, then yes, you need to name your module xml file to match your project. That is a GWT convention.