@Override public void close() { try { super.close(); } catch (IOException e) { throw new RuntimeIOException(e); } } }
private void emit(final GATKSAMRecord read) { // check to see whether the read was modified by looking at the temporary tag boolean wasModified = readsActuallyCleaned.contains(read); try { manager.addRead(read, wasModified); } catch (RuntimeIOException e) { throw new UserException.ErrorWritingBamFile(e.getMessage()); } }
@Test() public void pathWriterFailureMentionsCause() throws Exception { try { final Path outputPath = Paths.get("nope://no.txt"); createSmallBam(outputPath); Assert.fail("Should have thrown a RuntimeIOException"); } catch (RuntimeIOException expected) { Assert.assertTrue(expected.getCause().toString().contains("NoSuchFileException")); } }
public void close() { try { writer.close(); } catch (RuntimeIOException e) { throw new UserException.ErrorWritingBamFile(e.getMessage()); } }
public void encode(final String str) { try { dos.writeUTF(str); } catch (IOException e) { throw new RuntimeIOException(e); } }
@Override public long skip(final long n) { try { return delegate.skip(n); } catch (final IOException e) { throw new RuntimeIOException(e); } }
@Override public void write(@SuppressWarnings("NullableProblems") final byte[] b) { try { out.write(b); } catch (final IOException e) { throw new RuntimeIOException(e); } }
@Override public void reset() { try { delegate.reset(); } catch (final IOException e) { throw new RuntimeIOException(e); } count = 0; }
@Override public void write(final byte[] object) { try { outputStream.write(object); } catch (IOException e) { throw new RuntimeIOException(e); } }
/** * Do any required flushing here. */ @Override public void finish() { try { out.close(); } catch (final IOException e) { throw new RuntimeIOException(e); } }
public void write(final byte b) { try { out.write((int) b); } catch (final IOException e) { throw new RuntimeIOException(e); } }
@Override public int read(@SuppressWarnings("NullableProblems") final byte[] b) { try { final int read = delegate.read(b); count += read; return read; } catch (final IOException e) { throw new RuntimeIOException(e); } }
@Override public void accept(OrderedByteArray t) { try { os.write(t.bytes); } catch (IOException e) { throw new RuntimeIOException(e); } } }
public void close() { peekedLine = null; try { reader.close(); } catch (IOException e) { throw new RuntimeIOException(e); } } }
/** * Do any required flushing here. */ public void finish() { try { out.close(); } catch (IOException e) { throw new RuntimeIOException(e); } }
/** * Do any required flushing here. */ @Override public void finish() { try { out.close(); } catch (final IOException e) { throw new RuntimeIOException(e); } }
@Override public int available() { try { return delegate.available(); } catch (final IOException e) { throw new RuntimeIOException(e); } }
@Override public void reset() { try { delegate.reset(); } catch (final IOException e) { throw new RuntimeIOException(e); } }
@Override public void write(final int value) { try { out.write(value); } catch (final IOException e) { throw new RuntimeIOException(e); } }
@Override public int read() { count++; try { return delegate.read(); } catch (final IOException e) { throw new RuntimeIOException(e); } }