EncodingHeuristics

EncodingHeuristics reads from a stream (which should be buffered) and attempts to guess what the encoding of the text in the stream is. If it fails to determine the type of the encoding, it returns the default UTF-8.

class Object
trait Matchable
class Any

Type members

Classlikes

Value members

Concrete methods

This utility method attempts to determine the XML character encoding by examining the input stream, as specified at w3.

This utility method attempts to determine the XML character encoding by examining the input stream, as specified at w3.

Value parameters:
in

InputStream to read from.

Returns:

the name of the encoding.

Throws:
java.io.IOException

if the stream cannot be reset