Class CharsetUtilities
- java.lang.Object
-
- jetbrains.buildServer.nio.charset.CharsetUtilities
-
public abstract class CharsetUtilities extends Object
- Since:
- 9.1
- Author:
- Andrey Shcheglov <mailto:andrey.shcheglov@jetbrains.com>
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static CharsetdetectCharset(File path)static booleanisBinary(File input)Returnstrueifinputis binary,falseotherwise.
-
-
-
Method Detail
-
isBinary
@NotOomeSafe("Files.readAllBytes()") public static boolean isBinary(@NotNull File input) throws IOException
Returns
trueifinputis binary,falseotherwise. Note that for UTF-16 encoded files this method will always returntrue, so UTF-16 detection should be invoked before this method is called.- Returns:
trueifinputis binary,falseotherwise.- Throws:
IOException
-
-