Where does Eclipse store preferences?(Eclipse 在哪里存储首选项?)
问题描述
当我在如下屏幕截图所示的窗口中更改设置时,这些设置实际存储在哪里?
When I change a setting in a window like in the screenshot below, where are those settings actually stored?
奖励:有什么方法可以使用 Java、Eclipse RCP 等以编程方式访问设置?
Bonus: Is there any way, using Java, Eclipse RCP etc, to access the settings programmatically?
谢谢!
推荐答案
来源:Eclipse wiki
如果您想将首选项从一个版本保留到另一个版本,请使用 File/Export/Preferences 导出它们.
If you want to keep preferences from one version to the other, export them using File/Export/Preferences.
首选项存储在不同的地方(这适用于 Eclipse 3.1)
Preferences are stored in various places (this applies to Eclipse 3.1)
对于每个安装(但对于多用户安装,这可能会有所不同),存储在以下文件中:<eclipse_home>/eclipse/configuration/.settings/
for each installation (but this may vary for multi-user installations), in files stored in:
<eclipse_home>/eclipse/configuration/.settings/
每个插件通常有一个文件,带有 prefs 扩展名.请注意,很少有插件使用安装范围的首选项.
There is typically one file per plugin, with a prefs extension. Note that very few plug-ins use installation-wide preferences.
对于每个工作区,在 中存储的文件中.
for each workspace, in files stored in <workspace>/.metadata/.plugins/org.eclipse.core.runtime/.settings .
每个插件通常有一个文件,带有 prefs 扩展名.对于每个项目 -- 用于项目级设置 -- 存储在项目文件夹的 .settings 子目录中的文件中.
There is typically one file per plugin, with a prefs extension. for each project --for project-level settings -- in files stored in a .settings sub-directory of your project folder.
这里使用java代码访问首选项的文章.
Here's the article to access preferences using java code.
这篇关于Eclipse 在哪里存储首选项?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持编程学习网!
本文标题为:Eclipse 在哪里存储首选项?
基础教程推荐
- Struts2 URL 无法访问 2022-01-01
- 存储 20 位数字的数据类型 2022-01-01
- 修改 void 函数的输入参数,然后读取 2022-01-01
- Spring AOP错误无法懒惰地为此建议构建thisJoinPoin 2022-09-13
- 如何对 Java Hashmap 中的值求和 2022-01-01
- REST Web 服务返回 415 - 不支持的媒体类型 2022-01-01
- 问题http://apache.org/xml/features/xinclude测试日志4j 2 2022-01-01
- 无法复制:“比较方法违反了它的一般约定!" 2022-01-01
- RabbitMQ:消息保持“未确认"; 2022-01-01
- 使用堆栈算法进行括号/括号匹配 2022-01-01
