Package liquibase.io

Class EmptyLineAndCommentSkippingInputStream

  • All Implemented Interfaces:
    Closeable, AutoCloseable

    public class EmptyLineAndCommentSkippingInputStream
    extends BufferedInputStream
    Input stream that does not read (skips) lines starting with commentPattern and line endings. read() method will not return either line endings or commented lines.
    • Field Detail

    • Constructor Detail

      • EmptyLineAndCommentSkippingInputStream

        public EmptyLineAndCommentSkippingInputStream​(InputStream in,
                                                      String commentLineStartsWith)
        Creates Input stream that does not read (skips) lines starting with commentLineStartsWith
        Parameters:
        in - original input stream
        commentLineStartsWith - comment line pattern (if empty or null, comments will not be enabled)