Package org.apache.tools.ant.util
Class NullOutputStream
java.lang.Object
java.io.OutputStream
org.apache.tools.ant.util.NullOutputStream
- All Implemented Interfaces:
java.io.Closeable
,java.io.Flushable
,java.lang.AutoCloseable
public class NullOutputStream
extends java.io.OutputStream
OutputStream that completely discards all data written to it.
- Since:
- Ant 1.10.10
-
Field Summary
Fields Modifier and Type Field Description static NullOutputStream
INSTANCE
Shared instance which is safe to use concurrently as the stream doesn't hold any state at all. -
Method Summary
-
Field Details
-
INSTANCE
Shared instance which is safe to use concurrently as the stream doesn't hold any state at all.
-
-
Method Details
-
write
public void write(byte[] b)Doesn't do anything.- Overrides:
write
in classjava.io.OutputStream
-
write
public void write(byte[] b, int off, int len)Doesn't do anything.- Overrides:
write
in classjava.io.OutputStream
-
write
public void write(int i)Doesn't do anything.- Specified by:
write
in classjava.io.OutputStream
-