@Issue("#141") @Test @Ignore public void writeLogToWithLargeFile() throws Exception { Path path = Files.createTempFile("stapler-test", ".log.gz"); long size = Integer.MAX_VALUE + 256L; writeLargeFile(path, size); LargeText t = new LargeText(path.toFile(), StandardCharsets.US_ASCII, true); try (OutputStream os = new NullOutputStream()) { long writenCount = t.writeLogTo(0, os); assertEquals(size, writenCount); } Files.delete(path); }
public long writeLogTo(long start, Writer w) throws IOException { return writeLogTo(start, new WriterOutputStream(w, charset)); }
LargeText { public long writeLogTo(long start, Writer w) throws IOException { return writeLogTo(start, new WriterOutputStream(w, charset)); } }
LargeText { public long writeLogTo(long start, Writer w) throws IOException { return writeLogTo(start, new WriterOutputStream(w, charset)); } LargeText(File file, boolean completed);  LargeText(File file, boolean completed, boolean transparentGunzip);  LargeText(final File file, Charset charset, boolean completed);  LargeText(final File file, Charset charset, boolean completed, boolean transparentGunzip);  LargeText(ByteBuffer memory, boolean completed);  LargeText(final ByteBuffer memory, Charset charset, boolean completed); }
LargeText { public long writeLogTo(long start, Writer w) throws IOException { return writeLogTo(start, new WriterOutputStream(w, charset)); } LargeText(File file, boolean completed);  LargeText(File file, boolean completed, boolean transparentGunzip);  LargeText(final File file, Charset charset, boolean completed);  LargeText(final File file, Charset charset, boolean completed, boolean transparentGunzip);  LargeText(ByteBuffer memory, boolean completed);  LargeText(final ByteBuffer memory, Charset charset, boolean completed); void markAsComplete(); boolean isComplete(); long length(); Reader readAll(); long writeLogTo(long start, Writer w); long writeLogTo(long start, OutputStream out); void doProgressText(StaplerRequest req, StaplerResponse rsp); }
LargeText { public long writeLogTo(long start, Writer w) throws IOException { return writeLogTo(start, new WriterOutputStream(w, charset)); } LargeText(File file, boolean completed);  LargeText(File file, boolean completed, boolean transparentGunzip);  LargeText(final File file, Charset charset, boolean completed);  LargeText(final File file, Charset charset, boolean completed, boolean transparentGunzip);  LargeText(ByteBuffer memory, boolean completed);  LargeText(final ByteBuffer memory, Charset charset, boolean completed); void markAsComplete(); boolean isComplete(); long length(); Reader readAll(); long writeLogTo(long start, Writer w); long writeLogTo(long start, OutputStream out); void doProgressText(StaplerRequest req, StaplerResponse rsp);  }