Class ClosedOutputStream

  • All Implemented Interfaces:
    Closeable, Flushable, AutoCloseable

    public class ClosedOutputStream
    extends OutputStream
    Throws an exception on all attempts to write to the stream.

    Typically uses of this class include testing for corner cases in methods that accept an output stream and acting as a sentinel value instead of a null output stream.


Copyright © 2002–2021 The Apache Software Foundation. All rights reserved.