org.freehep.util.io
Class NoCloseOutputStream
java.lang.Object
java.io.OutputStream
java.io.FilterOutputStream
java.io.BufferedOutputStream
org.freehep.util.io.NoCloseOutputStream
- All Implemented Interfaces:
- Closeable, Flushable
public class NoCloseOutputStream
- extends BufferedOutputStream
The NoCloseOutputStream ignores the close so that one can keep writing to the
underlying stream.
- Version:
- $Id: src/main/java/org/freehep/util/io/NoCloseOutputStream.java
96b41b903496 2005/11/21 19:50:18 duns $
- Author:
- Mark Donszelmann
|
Method Summary |
void |
close()
|
void |
realClose()
Closes the stream (the close method is ignored). |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
NoCloseOutputStream
public NoCloseOutputStream(OutputStream stream)
- Creates a No Close output stream.
- Parameters:
stream - stream to write to
NoCloseOutputStream
public NoCloseOutputStream(OutputStream stream,
int size)
- Creates a No Close output stream.
- Parameters:
stream - stream to write tosize - buffer size
close
public void close()
throws IOException
- Specified by:
close in interface Closeable- Overrides:
close in class FilterOutputStream
- Throws:
IOException
realClose
public void realClose()
throws IOException
- Closes the stream (the close method is ignored).
- Throws:
IOException - if the close fails
Copyright © 2012. All Rights Reserved.