Method
readBuf
(byte[] out, int offset, int length)
Source from the content-addressed store, hash-verified
| 79 | } |
| 80 | |
| 81 | private int readBuf(byte[] out, int offset, int length) throws IOException |
| 82 | { |
| 83 | if (avail <= 0) |
| 84 | { |
| 85 | fillBuf(); |
| 86 | if (avail <= 0) |
| 87 | return -1; |
| 88 | } |
| 89 | if (length > avail) |
| 90 | length = avail; |
| 91 | System.arraycopy(buf, len - avail, out, offset, length); |
| 92 | avail -= length; |
| 93 | return length; |
| 94 | } |
| 95 | |
| 96 | private void readFully(byte[] out) throws IOException |
| 97 | { |
Tested by
no test coverage detected