Class BOMSkipper


  • public class BOMSkipper
    extends java.lang.Object
    • Constructor Summary

      Constructors 
      Constructor Description
      BOMSkipper()  
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static void skip​(java.io.Reader reader)
      Some text editors (e.g.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • BOMSkipper

        public BOMSkipper()
    • Method Detail

      • skip

        public static void skip​(java.io.Reader reader)
        Some text editors (e.g. Notepad on Windows) write a BOM as first character, when writing an UTF-8 encoded text file. BOMs are unicode characters encoded as 2,3, or 4-byte sequence specific for the unicode type (UTF-8, 16, ...) and little vs. big-endian byte order. Java Readers and InputStreams don't filter BOM out of the stream. Thus, we need to do it ourselfes.
        Parameters:
        reader -