MCPcopy Create free account
hub / github.com/apache/tomcat / read

Method read

test/org/apache/coyote/ajp/SimpleAjpClient.java:405–418  ·  view source on GitHub ↗
(InputStream is, byte[] buf, int pos, int n)

Source from the content-addressed store, hash-verified

403 }
404
405 protected boolean read(InputStream is, byte[] buf, int pos, int n) throws IOException {
406
407 int read = 0;
408 int res = 0;
409 while (read < n) {
410 res = is.read(buf, read + pos, n - read);
411 if (res > 0) {
412 read += res;
413 } else {
414 throw new IOException("Read failed");
415 }
416 }
417 return true;
418 }
419}

Callers 1

readMessageMethod · 0.95

Calls 1

readMethod · 0.65

Tested by

no test coverage detected