|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object java.io.Writer org.apache.commons.io.output.NullWriter
public class NullWriter
This Writer
writes all data to the famous /dev/null.
This Writer
has no destination (file/socket etc.) and all
characters written to it are ignored and lost.
Field Summary | |
---|---|
static NullWriter |
NULL_WRITER
A singleton. |
Fields inherited from class java.io.Writer |
---|
lock |
Constructor Summary | |
---|---|
NullWriter()
Constructs a new NullWriter. |
Method Summary | |
---|---|
Writer |
append(char c)
Does nothing - output to /dev/null . |
Writer |
append(CharSequence csq)
Does nothing - output to /dev/null . |
Writer |
append(CharSequence csq,
int start,
int end)
Does nothing - output to /dev/null . |
void |
close()
|
void |
flush()
|
void |
write(char[] chr)
Does nothing - output to /dev/null . |
void |
write(char[] chr,
int st,
int end)
Does nothing - output to /dev/null . |
void |
write(int idx)
Does nothing - output to /dev/null . |
void |
write(String str)
Does nothing - output to /dev/null . |
void |
write(String str,
int st,
int end)
Does nothing - output to /dev/null . |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final NullWriter NULL_WRITER
Constructor Detail |
---|
public NullWriter()
Method Detail |
---|
public Writer append(char c)
/dev/null
.
append
in interface Appendable
append
in class Writer
c
- The character to write
public Writer append(CharSequence csq, int start, int end)
/dev/null
.
append
in interface Appendable
append
in class Writer
csq
- The character sequence to writestart
- The index of the first character to writeend
- The index of the first character to write (exclusive)
public Writer append(CharSequence csq)
/dev/null
.
append
in interface Appendable
append
in class Writer
csq
- The character sequence to write
public void write(int idx)
/dev/null
.
write
in class Writer
idx
- The character to writepublic void write(char[] chr)
/dev/null
.
write
in class Writer
chr
- The characters to writepublic void write(char[] chr, int st, int end)
/dev/null
.
write
in class Writer
chr
- The characters to writest
- The start offsetend
- The number of characters to writepublic void write(String str)
/dev/null
.
write
in class Writer
str
- The string to writepublic void write(String str, int st, int end)
/dev/null
.
write
in class Writer
str
- The string to writest
- The start offsetend
- The number of characters to writepublic void flush()
flush
in interface Flushable
flush
in class Writer
Writer.flush()
public void close()
close
in interface Closeable
close
in class Writer
Writer.close()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |