生成本地化的 javadoc [英] Generate localized javadoc

查看:33
本文介绍了生成本地化的 javadoc的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想知道是否有一种生成本地化 javadoc 的简单方法:我想在 html 中翻译(例如法语)标题和关键字,而不是返回"、参数"、类".

I would like to know if there was a simple way of generating localized javadoc : I would like to have translated (for example in french) title and keywords instead of "return", "parameter", "class" in the html.

推荐答案

正如 Matt Ball 所说,你可以向 javadoc 提供 -locale 选项来影响一些事情.问题是tools.jar只包含默认的英文和另外一个日文(ja)和一个中文(cn_ZH)翻译.

As said by Matt Ball, you can provide the -locale option to javadoc to influence some things. The problem is that tools.jar only contains the default English and additionally one Japanese (ja) and one Chinese (cn_ZH) translation.

我刚刚试过中文的,它有效:它写抛出:JSchException而不是抛出:JSchException.

I just tried the Chinese one, and it works: it writes 抛出: JSchException instead of Throws: JSchException.

因此,您必须将这些翻译成您的语言(如果您不想要其中之一).

So you would have to translate these to your language (if you don't want one of these).

几年前,我为当时的版本(1.2 或更高版本)创建了这些资源的世界语翻译,如果您有兴趣,我可以将它们挖掘出来.(但现在他们似乎在使用另一种格式.)

Some years ago I created an Esperanto translation of those resources for the then-current version (1.2 or such), if you are interested I could dig them out. (But it seems now they are using another format.)

这篇关于生成本地化的 javadoc的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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