01: /*
02: * Streams that have a different close mechanism.
03: * Copyright (C) 2003 Stephen Ostermiller
04: * http://ostermiller.org/contact.pl?regarding=Java+Utilities
05: *
06: * This program is free software; you can redistribute it and/or modify
07: * it under the terms of the GNU General Public License as published by
08: * the Free Software Foundation; either version 2 of the License, or
09: * (at your option) any later version.
10: *
11: * This program is distributed in the hope that it will be useful,
12: * but WITHOUT ANY WARRANTY; without even the implied warranty of
13: * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14: * GNU General Public License for more details.
15: *
16: * See COPYING.TXT for details.
17: */
18: package com.Ostermiller.util;
19:
20: import java.io.*;
21:
22: /**
23: * A wrapper for a stream (either input or output)
24: * which has a close method with no effect.
25: * More information about this class is available from <a target="_top" href=
26: * "http://ostermiller.org/utils/NoCloseStream.html">ostermiller.org</a>.
27: *
28: * @author Stephen Ostermiller http://ostermiller.org/contact.pl?regarding=Java+Utilities
29: * @since ostermillerutils 1.01.00
30: */
31: public interface NoCloseStream {
32:
33: /**
34: * Actually closes this stream and releases any system
35: * resources associated with the stream, as opposed to
36: * the close() method, which does nothing.
37: *
38: * @throws IOException if an I/O error occurs.
39: *
40: * @since ostermillerutils 1.01.00
41: */
42: public void reallyClose() throws IOException;
43:
44: }
|