Rev | Line | |
---|
[13350] | 1 | /*
|
---|
| 2 | * FinishableOutputStream
|
---|
| 3 | *
|
---|
| 4 | * Author: Lasse Collin <lasse.collin@tukaani.org>
|
---|
| 5 | *
|
---|
| 6 | * This file has been put into the public domain.
|
---|
| 7 | * You can do whatever you want with this file.
|
---|
| 8 | */
|
---|
| 9 |
|
---|
| 10 | package org.tukaani.xz;
|
---|
| 11 |
|
---|
| 12 | import java.io.OutputStream;
|
---|
| 13 | import java.io.IOException;
|
---|
| 14 |
|
---|
| 15 | /**
|
---|
| 16 | * Output stream that supports finishing without closing
|
---|
| 17 | * the underlying stream.
|
---|
| 18 | */
|
---|
| 19 | public abstract class FinishableOutputStream extends OutputStream {
|
---|
| 20 | /**
|
---|
| 21 | * Finish the stream without closing the underlying stream.
|
---|
| 22 | * No more data may be written to the stream after finishing.
|
---|
| 23 | * <p>
|
---|
| 24 | * The <code>finish</code> method of <code>FinishableOutputStream</code>
|
---|
| 25 | * does nothing. Subclasses should override it if they need finishing
|
---|
| 26 | * support, which is the case, for example, with compressors.
|
---|
| 27 | *
|
---|
| 28 | * @throws IOException
|
---|
| 29 | */
|
---|
| 30 | public void finish() throws IOException {}
|
---|
| 31 | }
|
---|
Note:
See
TracBrowser
for help on using the repository browser.