好的Java属性文件编辑器 [英] Good Java property files editor

查看:221
本文介绍了好的Java属性文件编辑器的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在一个开源Java项目上工作,我们有很多资源属性文件,其中包含可本地化的消息资源。这些文件由志愿者翻译成20多种语言,我是主要编辑代码的开发人员。

I work on an open-source Java project, and we have a lot of resource property files that contains localizable message resources. Those files are translated by volunteers to 20+ languages, and I'm a developer who primarily edits code.

在Java中,不同语言环境的资源文件由一个组合在一起命名惯例。例如,如果默认(通常是英语)资源是foo.properties,则日语资源在foo_ja.properties中,法语是foo_fr.properties,等等。为了这个问题,让我们调用这个组资源组。

In Java, resource files for different locales are grouped together by a naming convention. For example, if the default (normally English) resource is "foo.properties", Japanese resource is in "foo_ja.properties", French one is "foo_fr.properties", etc. For the sake of this question, let's call this group a "resource group."

现在,我经常需要重构这些资源文件。另外,我需要该工具来支持属性文件的基础知识。总而言之,我的要求列表如下:

Now, every so often, I need to refactor those resource files. In addition, I need the tool to support the basics of the property files. All in all, my list of requirements are something like:


  1. 重命名属性键名称,我想要一个工具来重命名所有键同一组中的所有文件,没有我单独浏览它们。

  2. 将属性从一个资源组移动到另一个资源组,我想要一个工具来为每个资源文件执行此操作。 group of。

  3. 在Java中,资源文件采用ISO-8859-1编码,而不是平台默认编码。

  4. 我不知道想要在编辑/浏览属性文件时看到\ uXXXX,但我确实希望该工具能够保留它们。

  5. 我不希望该工具重新排列资源中属性的顺序文件,也没有评论。我希望该工具能够保留它们。

  6. 我希望该工具能够处理资源文件的其他语法细节,例如多行文本。

  1. Renaming property key name, and I want a tool to rename all the keys in all the files in the same group, without me individually going through them.
  2. Move a property from one resource group to another, and I want a tool to do so for each resource file in the group.
  3. In Java, resource files are in the ISO-8859-1 encoding and not in the platform default encoding.
  4. I don't want to see \uXXXX when editing/browsing property files, but I do expect the tool to preserve them.
  5. I don't want the tool to rearrange the order of properties in the resource file, nor mess with the comments. I expect the tool to preserve them.
  6. I want the tool to handle other syntax details of resource files, such as multiline text.

不幸的是,我找不到符合这些标准的好工具。我主要是IntelliJ IDEA用户,但它不做#2和#3。 Eclipse内置的属性文件编辑器更糟糕,而AFAICT它没有做#1,#2,#4。实际上,它缺少跨越同一组中的资源文件的视图。 NetBeans同样是原始的。 NetBeans也是如此,尽管它确实是#4。

Unfortunately, I'm not finding any good tool that fits these criteria. I'm primarily an IntelliJ IDEA user, but it doesn't do #2 and #3. Eclipse built-in property file editor is even worse, and AFAICT it doesn't do #1, #2, #4. In fact it lacks the view that cuts across resource files in the same group. NetBeans is similarly primitive. The same goes for NetBeans, although it does #4.

有没有人知道一个适合账单的好工具?

Does anyone know of a good tool that fits the bill?

推荐答案

此时,我想答案是Java中没有与列出的标准匹配的好的属性文件编辑器。 prbeditor听起来很有希望,但它已经消失了,IntelliJ IDEA在纸面上看起来不错,但却遇到了一个严重的错误,然后Eclipse插件都有些原始。

At this point, I guess the answer is that there is no good property files editor in Java that matches the listed criteria. prbeditor sounded promising but it's gone, IntelliJ IDEA looks good on paper but is suffering a critical bug, and then the Eclipse plugins are all somewhat primitive.

这篇关于好的Java属性文件编辑器的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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