MCPcopy Create free account
hub / github.com/antlr/codebuff / skipFully

Method skipFully

corpus/java/training/guava/io/ByteStreams.java:755–761  ·  view source on GitHub ↗

Discards n bytes of data from the input stream. This method will block until the full amount has been skipped. Does not close the stream. @param in the input stream to read from @param n the number of bytes to skip @throws EOFException if this stream reaches the end before skipping all the

(InputStream in, long n)

Source from the content-addressed store, hash-verified

753 * @throws IOException if an I/O error occurs, or the stream does not support skipping
754 */
755 public static void skipFully(InputStream in, long n) throws IOException {
756 long skipped = skipUpTo(in, n);
757 if (skipped < n) {
758 throw new EOFException(
759 "reached end of stream after skipping " + skipped + " bytes; " + n + " bytes expected");
760 }
761 }
762
763 /**
764 * Discards up to {@code n} bytes of data from the input stream. This method will block until

Callers

nothing calls this directly

Calls 1

skipUpToMethod · 0.95

Tested by

no test coverage detected