public final class CharsetDetector extends Object
| 构造器和说明 |
|---|
CharsetDetector() |
| 限定符和类型 | 方法和说明 |
|---|---|
static String |
detect(File file)
探测文件内容字符集
|
static String |
detect(InputStream inputStream)
探测流内容字符集内容
|
static String |
detect(String path)
Detecting a file content character set based on a file path
依据文件路径探测文件内容字符集
|
static String |
detectStr(String content)
Detector string content character set
探测字符串内容字符集
|
public static String detectStr(String content) throws IOException
content - 字符串内容IOExceptionpublic static String detect(String path) throws IOException
path - the path of file
文件路径IOExceptionpublic static String detect(File file) throws IOException
IOExceptionpublic static String detect(InputStream inputStream) throws IOException
IOExceptionCopyright © 2018. All rights reserved.