java.lang.Object
java.io.OutputStream
com.aoapps.lang.io.NullOutputStream
- All Implemented Interfaces:
NoClose
,Closeable
,Flushable
,AutoCloseable
Discards all data.
-
Method Summary
Modifier and TypeMethodDescriptionvoid
close()
Calls to close are ignored whenNoClose.isNoClose()
, otherwise some action might be taken which means close calls to this object may not be skipped or assumed to be ignored.void
flush()
static NullOutputStream
void
write
(byte[] b) void
write
(byte[] b, int off, int len) void
write
(int b) Methods inherited from class java.io.OutputStream
nullOutputStream
-
Method Details
-
getInstance
-
close
public void close()Description copied from interface:NoClose
Calls to close are ignored whenNoClose.isNoClose()
, otherwise some action might be taken which means close calls to this object may not be skipped or assumed to be ignored.- Specified by:
close
in interfaceAutoCloseable
- Specified by:
close
in interfaceCloseable
- Specified by:
close
in interfaceNoClose
- Overrides:
close
in classOutputStream
-
flush
public void flush()- Specified by:
flush
in interfaceFlushable
- Overrides:
flush
in classOutputStream
-
write
public void write(byte[] b) - Overrides:
write
in classOutputStream
-
write
public void write(byte[] b, int off, int len) - Overrides:
write
in classOutputStream
-
write
public void write(int b) - Specified by:
write
in classOutputStream
-