Java如何确定'file.encoding'系统属性?

Joh*_*Lim 9 java encoding locale

我认为Java按系统区域设置确定'file.encoding'系统属性.

但在我的系统中,系统区域设置为'ko_kr.UTF-8'时,'file.encoding'为'ANSI_X3.4-1968'.

Java如何确定'file.encoding'系统属性?

sre*_*gam 1

从以下链接填充属性的本机代码(适用于Solaris,Linux操作系统)

下面的本机方法加载系统属性。

private static native Properties initProperties(Properties props);
Run Code Online (Sandbox Code Playgroud)

下面的链接是加载属性的本机代码链接(第187行之后)

设置java属性的源