@Test public void testWrite() throws Exception { DistributedLogManager dlm = mock(DistributedLogManager.class); AppendOnlyStreamWriter writer = mock(AppendOnlyStreamWriter.class); DLOutputStream out = new DLOutputStream(dlm, writer); byte[] data = new byte[16]; out.write(data); verify(writer, times(1)).write(data); }
@Override public void write(int b) throws IOException { byte[] data = new byte[] { (byte) b }; write(data); }
DLOutputStream extends OutputStream { @Override public void write(int b) throws IOException { byte[] data = new byte[] { (byte) b }; write(data); } }
DLOutputStream extends OutputStream { @Override public void write(int b) throws IOException { byte[] data = new byte[] { (byte) b }; write(data); } DLOutputStream(DistributedLogManager dlm,
                        AppendOnlyStreamWriter writer); }
DLOutputStream extends OutputStream { @Override public void write(int b) throws IOException { byte[] data = new byte[] { (byte) b }; write(data); } DLOutputStream(DistributedLogManager dlm,
                        AppendOnlyStreamWriter writer); @Override void write(int b); @Override void write(byte[] b, int off, int len); @Override void write(byte[] b); @Override void flush(); @Override void close(); }
DLOutputStream extends OutputStream { @Override public void write(int b) throws IOException { byte[] data = new byte[] { (byte) b }; write(data); } DLOutputStream(DistributedLogManager dlm,
                        AppendOnlyStreamWriter writer); @Override void write(int b); @Override void write(byte[] b, int off, int len); @Override void write(byte[] b); @Override void flush(); @Override void close();  }