Package net.markenwerk.commons.nulls
Class NullWriter
- java.lang.Object
-
- java.io.Writer
-
- net.markenwerk.commons.nulls.NullWriter
-
- All Implemented Interfaces:
Closeable
,Flushable
,Appendable
,AutoCloseable
public class NullWriter extends Writer
ANullWriter
is aWriter
that does nothing.- Since:
- 1.0.0
- Author:
- Torsten Krause (tk at markenwerk dot net)
-
-
Constructor Summary
Constructors Constructor Description NullWriter()
Creates a newNullWriter
.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
close()
void
flush()
void
write(char[] buffer, int offset, int length)
-
-
-
Constructor Detail
-
NullWriter
public NullWriter()
Creates a newNullWriter
.
-
-
Method Detail
-
write
public void write(char[] buffer, int offset, int length) throws IOException
- Specified by:
write
in classWriter
- Throws:
IOException
-
flush
public void flush() throws IOException
- Specified by:
flush
in interfaceFlushable
- Specified by:
flush
in classWriter
- Throws:
IOException
-
close
public void close() throws IOException
- Specified by:
close
in interfaceAutoCloseable
- Specified by:
close
in interfaceCloseable
- Specified by:
close
in classWriter
- Throws:
IOException
-
-