我真的很想知道该文件是否是Windows-1256。有没有办法在Java中识别文本文件是否为Windows-1256?
最佳答案
您可以使用此 API 来检查编码:
http://jchardet.sourceforge.net/
看看这个问题:
Java : How to determine the correct charset encoding of a stream
关于java - 如何检测文本文件是否使用 Windows-1256 编码?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/10170037/