Package com.gengoai.io
Class CharsetDetector
- java.lang.Object
-
- com.gengoai.io.CharsetDetector
-
public class CharsetDetector extends Object
Convenience method for detecting the character set of a byte array.- Author:
- David B. Bracewell
-
-
Constructor Summary
Constructors Constructor Description CharsetDetector()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static Charset
detect(byte[] buffer, int offset, int length)
Detects the character set for the buffer.
-
-
-
Method Detail
-
detect
public static Charset detect(byte[] buffer, int offset, int length)
Detects the character set for the buffer.- Parameters:
buffer
- The bufferoffset
- where to startlength
- the length to read- Returns:
- The detected charset or null
-
-