使用谷歌翻译 三种方式
1,谷歌官方发布 rest api
http://code.google.com/intl/zh-CN/apis/language/translate/v2/getting_started.html
使用rest
import com.google.api.translate.Language;import com.google.api.translate.Translate;public class Main { public static void main(String[] args) throws Exception { // Set the HTTP referrer to your website address. Translate.setHttpReferrer(/* Enter the URL of your site here */); String translatedText = Translate.execute("Bonjour le monde", Language.FRENCH, Language.ENGLISH); System.out.println(translatedText); }}