Class UnicodeReader

java.lang.Object
java.io.Reader
de.hybris.bootstrap.xml.UnicodeReader
All Implemented Interfaces:
Closeable, AutoCloseable, Readable

public class UnicodeReader extends Reader
Generic unicode textreader, which will use BOM mark to identify the encoding to be used. If BOM is not found then use a given default encoding. System default is used if: BOM mark is not found and defaultEnc is NULL

Usage pattern: String defaultEnc = "ISO-8859-1"; // or NULL to use system default FileInputStream fis = new FileInputStream(file); Reader in = new UnicodeReader(fis, defaultEnc);