Add simple performance optimization

This commit is contained in:
René Pfeuffer
2020-06-10 14:31:32 +02:00
parent 4bbc06f30c
commit b8dc613c78

View File

@@ -71,6 +71,14 @@ class LineFilteredOutputStream extends OutputStream {
}
}
@Override
public void write(byte[] b, int off, int len) throws IOException {
if (currentLine > end) {
return;
}
super.write(b, off, len);
}
public void keepLineBreakInMind(char b) {
lastLineBreakCharacter = b;
++currentLine;