有没有办法检查文本文件 (.txt) 是使用 Unicode 编码还是使用 Java 使用 UTF-8 编码?
最佳答案
您无法绝对确定在一般情况下使用哪个字符集。我发现这是一本好书。
http://illegalargumentexception.blogspot.co.uk/2009/05/java-rough-guide-to-character-encoding.html
特别是自动检测编码部分。
关于java - 有没有办法用 Java 检查 .txt 文件的字符集编码?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/11022497/