net.sf.mmm.util.io.api
Class DevNullTarget

java.lang.Object
  extended by java.io.OutputStream
      extended by net.sf.mmm.util.io.api.DevNullTarget
All Implemented Interfaces:
Closeable, Flushable

public final class DevNullTarget
extends OutputStream

This is an implementation of /dev/null as OutputStream. In other words the DevNullTarget is a dummy OutputStream that ignores all the data written.

Since:
1.0.0
Author:
Joerg Hohwiller (hohwille at users.sourceforge.net)

Field Summary
static DevNullTarget INSTANCE
          The singleton instance.
 
Constructor Summary
private DevNullTarget()
          The constructor.
 
Method Summary
 void close()
          
 void write(byte[] b, int off, int len)
          
 void write(int b)
          
 
Methods inherited from class java.io.OutputStream
flush, write
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

INSTANCE

public static final DevNullTarget INSTANCE
The singleton instance.

Constructor Detail

DevNullTarget

private DevNullTarget()
The constructor.

Method Detail

write

public void write(int b)

Specified by:
write in class OutputStream

write

public void write(byte[] b,
                  int off,
                  int len)

Overrides:
write in class OutputStream

close

public void close()

Specified by:
close in interface Closeable
Overrides:
close in class OutputStream


Copyright © 2001-2010 mmm-Team. All Rights Reserved.