MCPcopy Index your code
hub / github.com/google/brotli / read

Method read

java/org/brotli/wrapper/dec/BrotliInputStream.java:56–74  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

54 }
55
56 @Override
57 public int read() throws IOException {
58 if (decoder.closed) {
59 throw new IOException("read after close");
60 }
61 int decoded;
62 // Iterate until at least one byte is decoded, or EOF reached.
63 while (true) {
64 decoded = decoder.decode();
65 if (decoded != 0) {
66 break;
67 }
68 }
69
70 if (decoded == -1) {
71 return -1;
72 }
73 return decoder.buffer.get() & 0xFF;
74 }
75
76 @Override
77 public int read(byte[] b) throws IOException {

Callers 3

testZeroDictionaryMethod · 0.95
testSetRfcDictionaryMethod · 0.95
testEagerReadingMethod · 0.95

Calls 2

decodeMethod · 0.80
minMethod · 0.80

Tested by 3

testZeroDictionaryMethod · 0.76
testSetRfcDictionaryMethod · 0.76
testEagerReadingMethod · 0.76