gwt>导入示例项目
我刚刚花了两个小时试图强制它工作并在网上寻找答案。
究竟如何将示例 gwt 应用程序导入到 eclipse 中并使其运行?
顺便说一句,我在文件中的任何位置都找不到“projectCreator.cmd”,假设我已经使用 eclipse 插件更新程序来更新 d/l gwt 1.7.1,那么它在哪里?
I'm just barely after 2 hours of trying to force it to work and looking for answers online.
How in the world do you import a sample gwt application into your eclipse and make it run?
by the way, I cannot find "projectCreator.cmd" anywhere in my files, where is it suppose to be assumming i've used eclipse plugin updater to d/l gwt 1.7.1?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(4)
好吧,这就是我最终所做的,尽管它很丑陋,而且可能不是它本来的样子:
我创建了一个名为“bla”或其他名称的新应用程序
然后就在项目上>导入...>> General\file system...(如将文件导入到项目中)
然后我选择了示例应用程序之一的顶部文件夹,例如 ..gwt..samples/Mail
选择了所有文件夹和文件。
选择选项“覆盖而不警告\询问”
取消选择
与此相关的选项“复制整个文件夹结构”。我转到 build.XML 将项目名称重命名为“bla”,然后单击“作为 Web 应用程序运行”。
祝你好运。
Well, this is what I ended up doing though it ugly and probably not how it was meant to be:
I create a new application called it "bla" or whatever
then right on project > import... > general\file system... (as in import files into projects)
then I selected the top folder of one of the sample applications, for example ..gwt..samples/Mail
selected all folders and files.
selected option "override without warning\asking"
de-selected option "copy entire folder structure"
that's about it. I went to build.XML to rename the project name to "bla" and then I clicked run as a web application.
good luck.
对于 GWT 2.4:在每个项目的根目录中,您都会找到一个
README.txt
。如果您遵循其指示(涉及通过 Ant 创建 Eclipse 项目配置),您可以轻松导入项目。为了运行它,我还必须配置项目的 GWT 设置(项目的上下文菜单 -> Google -> WebToolkit 设置)。For GWT 2.4: In every project's root you will find a
README.txt
. If you follow its directions (involving creation of Eclipse project configuration via Ant) you can import the project easily. To run it I additionally had to configure the project's GWT settings (project's context menu -> Google -> WebToolkit settings).首先,为您的源代码创建一个 Eclipse 项目(如果您尚未这样做),请选择“File”>“新的> Java 项目。然后选择从现有源创建项目并设置您的项目。此时,您的源代码将加载到 Eclipse 中,但项目的构建路径可能未正确设置,并且您可能会看到构建错误。
或者,如果您的应用程序的源代码树已经包含 .project 文件,或者因为您之前在 Eclipse 中处理过它,或者因为它是由 GWT 的 webAppCreator 等工具生成的,您可以通过以下方式导入该项目:到文件>导入>常规并选择将现有项目放入工作区
要启用 Google Web Toolkit,请右键单击您的项目并选择 Google > Web 工具包设置。选中“使用 Google Web Toolkit”框并单击“确定”应用更改。
为您的项目启用 App Engine 的方法类似:右键单击您的项目并选择 Google >应用程序引擎设置。选中“使用 Google App Engine”框并单击“确定”。
来源:https://developers.google.com/eclipse/docs/现有项目
First, Create an Eclipse project for your source, if you haven't already done so, by selecting File > New > Java Project. Then choose Create project from existing source and set up your project. At this point, your source will be loaded in Eclipse, but the project's build path may not be set up properly, and you may see build errors.
Alternatively, if your application's source tree already contains a .project file, either because you had previously worked on it in Eclipse or because it was generated by a tool like GWT's webAppCreator, you can import the project by going to File > Import > General and selecting Existing Projects into Workspace
To enable Google Web Toolkit, right-click your project and select Google > Web Toolkit Settings. Check the Use Google Web Toolkit box and click OK to apply the change.
Enabling App Engine for your project is similar: right-click your project and select Google > App Engine Settings. Check the Use Google App Engine box and click OK.
Source : https://developers.google.com/eclipse/docs/existingprojects
我做了什么来启动它:
我的工作区位于:/Users/ievgennaloiko/Documents/helpdesk/
我已将 gwt 下载到“下载”文件夹。提取出来了从终端导航到示例并运行
我需要导入到 Eclipse 的每个示例项目。您甚至可以在整个示例项目上运行此命令。
接下来,我将示例文件夹复制到 /Users/ievgennaloiko/Documents/helpdesk
启动了 Eclipse。
文件导入->现有项目进入 ws -> /Users/ievgennaloiko/Documents/helpdesk/samples/DynaTable
将项目复制到 ws - 未选中。
接下来,我必须转到项目 Google-WebToolkit->Use web toolkit 的属性。
以下是我所使用的论点,请检查对应关系:
What I did to start it:
My workspace is at: /Users/ievgennaloiko/Documents/helpdesk/
I have downloaded the gwt to Downloads folder. Extracted it. Navigated from terminal to samples and run
for each sample project I need to import to Eclipse. Even you can run this command on whole sample project.
Next I've copied the samples folder to /Users/ievgennaloiko/Documents/helpdesk
Started Eclipse.
File import -> Existing proj into ws -> /Users/ievgennaloiko/Documents/helpdesk/samples/DynaTable
Copy project into ws - Unchecked.
Next I had to go to properties of the project Google-WebToolkit->Use web toolkit.
Here are the arguments I run with, check for correspondence: