Suppress remaining Checkstyle errors

This commit is contained in:
wb9688 2020-04-09 17:24:43 +02:00
parent ff9a1ebb1b
commit 03de4b29ea
4 changed files with 29 additions and 7 deletions

View File

@ -86,11 +86,11 @@ public class DataReader {
return high << 32 | low; return high << 32 | low;
} }
public int read(byte[] buffer) throws IOException { public int read(final byte[] buffer) throws IOException {
return read(buffer, 0, buffer.length); return read(buffer, 0, buffer.length);
} }
public int read(byte[] buffer, int offset, int count) throws IOException { public int read(final byte[] buffer, int offset, int count) throws IOException {
if (readCount < 0) { if (readCount < 0) {
return -1; return -1;
} }

View File

@ -640,7 +640,7 @@ public class Mp4FromDashWriter {
return size; return size;
} }
private byte[] makeMdat(long refSize, boolean is64) { private byte[] makeMdat(long refSize, final boolean is64) {
if (is64) { if (is64) {
refSize += 16; refSize += 16;
} else { } else {
@ -736,8 +736,10 @@ public class Mp4FromDashWriter {
int start = auxOffset(); int start = auxOffset();
auxWrite(new byte[]{ auxWrite(new byte[]{
0x00, 0x00, 0x00, 0x00, 0x74, 0x72, 0x61, 0x6B, // trak header // trak header
0x00, 0x00, 0x00, 0x68, 0x74, 0x6B, 0x68, 0x64, 0x01, 0x00, 0x00, 0x03 // tkhd header 0x00, 0x00, 0x00, 0x00, 0x74, 0x72, 0x61, 0x6B,
// tkhd header
0x00, 0x00, 0x00, 0x68, 0x74, 0x6B, 0x68, 0x64, 0x01, 0x00, 0x00, 0x03
}); });
ByteBuffer buffer = ByteBuffer.allocate(48); ByteBuffer buffer = ByteBuffer.allocate(48);

View File

@ -419,7 +419,7 @@ public class OggFromWebMWriter implements Closeable {
} }
} }
private int calcCrc32(int initialCrc, byte[] buffer, int size) { private int calcCrc32(int initialCrc, final byte[] buffer, final int size) {
for (int i = 0; i < size; i++) { for (int i = 0; i < size; i++) {
int reg = (initialCrc >>> 24) & 0xff; int reg = (initialCrc >>> 24) & 0xff;
initialCrc = (initialCrc << 8) ^ crc32Table[reg ^ (buffer[i] & 0xff)]; initialCrc = (initialCrc << 8) ^ crc32Table[reg ^ (buffer[i] & 0xff)];

View File

@ -10,4 +10,24 @@
<suppress checks="FinalParameters" <suppress checks="FinalParameters"
files="InfoListAdapter.java" files="InfoListAdapter.java"
lines="253,325"/> lines="253,325"/>
<!-- org.schabi.newpipe.streams -->
<suppress checks="FinalParameters"
files="DataReader.java"
lines="46,93"/>
<suppress checks="FinalParameters"
files="Mp4FromDashWriter.java"
lines="643"/>
<suppress checks="FinalParameters"
files="OggFromWebMWriter.java"
lines="380,422"/>
<suppress checks="FinalParameters"
files="WebMWriter.java"
lines="419,591"/>
<suppress checks="LineLength"
files="WebMWriter.java"
lines="156,158"/>
</suppressions> </suppressions>