1.什么是Run Configuration
run configration 定义了在程序启动过程中的一系列环境。比如Vm, plug-in classpath ,依赖等等。
2. 检查run configuration
上一篇文章中我们启动Application是通过.product文件中的Launch Application来启动。在这里介绍另外一种通过run as的配置文件来启动Application.
为了检查和编辑我们的run configuration ,从Eclipse IDE的菜单中选择 Run–> Run configurations ….
在Main选项卡中,Location 我们可以指定Eclipse 在运行时创建的一些必要的存储文件的位置。
3. Run Arguments
run configuration 允许我们在arguments中添加一些额外的信息。默认的情况下,Eclipse的这个选项卡下已经包含了一些信息。比如 -os, -ws, -arch 等等。
下表为一些常用的启动配置信息:
Parameter | Description |
---|---|
consoleLog | Error messages of the running Eclipse application are written to standard-out (System.out) which can be viewed in the Eclipse IDE Console view that started the RCP application. |
nl | Specifies the locale used for your application. The locale defines the language specific settings, i.e., which translation is used and the number, date and currency formatting. For example -nl en starts your application using the English language. This is useful for testing translations. |
console | Provides access to an OSGi console where you can check the status of your application. |
noExit | Keeps the OSGi console open even if the application crashes. This allows to analyze the application dependencies even if the application crashes during startup. |
clearPersistedState | Deletes cached runtime changes of the Eclipse 4 application model. |