001 package org.shiftone.jrat.util.io.nop; 002 003 004 import java.io.IOException; 005 import java.io.OutputStream; 006 007 008 /** 009 * @author jeff@shiftone.org (Jeff Drost) 010 */ 011 public class NullOutputStream extends OutputStream { 012 013 public static final OutputStream INSTANCE = new NullOutputStream(); 014 015 private NullOutputStream() { 016 } 017 018 019 public void write(int b) throws IOException { 020 } 021 022 023 public void close() throws IOException { 024 } 025 026 027 public void flush() throws IOException { 028 } 029 030 031 public void write(byte[] b, int off, int len) throws IOException { 032 } 033 034 035 public void write(byte[] b) throws IOException { 036 } 037 }