使用Eclipse与Play Framework 2.0 [英] Using Eclipse with Play Framework 2.0

查看:140
本文介绍了使用Eclipse与Play Framework 2.0的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我是Framework 2.0的新手。在播放1.0中,在您的项目取消后,您可以使用* .launch文件来启动项目。



在Play 2.0中,似乎没有任何类似的东西。有没有办法控制您的启动和使用Eclipse调试Play 2.0?



类似的问题:在Eclipse中调试Playframework 2.0



该问题的答案没有足够的具体

解决方案

问题1:



删除之后,打开Eclipse并选择 File - >导入... - >现有项目进入工作区。将打开一个对话框,选择您的Play Framework 2.0项目文件夹,然后单击完成



问题2:


  1. 使用播放调试运行启动Play Framework应用程序。你会看到这样的东西:



    在地址:9999
    ...

  2. 收听运输dt_socket
  3. 在Eclipse中,右键单击 Project Explorer 中的项目,然后选择调试为 - >调试配置...


  4. 将打开一个名为调试配置的新对话框。双击远程Java应用程序,右侧将显示一个新窗口。更改连接属性,以便指向主机 localhost 和端口 9999 。通过点击 Debug 按钮进行确认。


  5. 在Eclipse中的应用程序中放置一个断点。


  6. 在网络浏览器中正常尝试您的应用程序。如果它是一个断点,那么Eclipse将被带到最前面,让你调试。



I am new to Framework 2.0. In Play 1.0, after you Eclipsify your project, you have have a *.launch file that you can use to launch your project.

After you eclipsify in Play 2.0, you don't seem to have anything similar. Is there a way to control your launching and to debug Play 2.0, using Eclipse?

A similar question: Debug Playframework 2.0 in Eclipse

The answer to that question did not have specific enough instructions for me to know how to follow.

解决方案

Question 1:

After you have eclipsified, open Eclipse and choose File -> Import... -> Existing Projects into Workspace. A dialog will open, choose your Play Framework 2.0 project folder and click Finish.

Question 2:

  1. Start your Play Framework application using play debug run. You will see something like this:

    Listening for transport dt_socket at address: 9999 ...

  2. In Eclipse, right-click on your project in Project Explorer and choose Debug As -> Debug Configurations....

  3. A new dialog called Debug Configurations will open. Double-click on Remote Java Application and a new window will appear on the right side. Change the Connection properties so that the point to host localhost and port 9999. Confirm by clicking the Debug button.

  4. Put a breakpoint in your Application in Eclipse.

  5. Try your application as normal in a web-browser. If it hits a breakpoint then Eclipse will be brought as frontmost and let you debug.

这篇关于使用Eclipse与Play Framework 2.0的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆