Skip navigation links

Oracle® Coherence Java API Reference
Release 3.6.0.0

E15725-01


com.tangosol.util
Class NullImplementation.NullOutputStream

java.lang.Object
  extended by java.io.OutputStream
      extended by com.tangosol.util.NullImplementation.NullOutputStream

All Implemented Interfaces:
OutputStreaming, Closeable, DataOutput, Flushable
Enclosing class:
NullImplementation

public static class NullImplementation.NullOutputStream
extends OutputStream
implements OutputStreaming, DataOutput

An OutputStream that does basically nothing. Note that multiple instances are required because the API dictates that the close method must cause further invocations to all other methods to throw an IOException.

Author:
cp 2000.11.01

Method Summary
 void close()
          Closes this OutputStream and releases any associated system resources.
 void flush()
          Flushes this OutputStream and forces any buffered output bytes to be written.
 int size()
           
 void write(byte[] b)
          Writes all the bytes in the array ab.
 void write(byte[] b, int off, int len)
          Writes cb bytes starting at offset of from the array ab.
 void write(int b)
          Writes the eight low-order bits of the argument b.
 void writeBoolean(boolean v)
           
 void writeByte(int v)
           
 void writeBytes(String s)
           
 void writeChar(int v)
           
 void writeChars(String s)
           
 void writeDouble(double v)
           
 void writeFloat(float v)
           
 void writeInt(int v)
           
 void writeLong(long v)
           
 void writeShort(int v)
           
 void writeUTF(String s)
           

 

Method Detail

write

public void write(int b)
           throws IOException
Description copied from interface: OutputStreaming
Writes the eight low-order bits of the argument b. The 24 high-order bits of b are ignored.
Specified by:
write in interface OutputStreaming
Specified by:
write in interface DataOutput
Specified by:
write in class OutputStream
Parameters:
b - the byte to write (passed as an integer)
Throws:
IOException - if an I/O error occurs

write

public void write(byte[] b)
           throws IOException
Description copied from interface: OutputStreaming
Writes all the bytes in the array ab.
Specified by:
write in interface OutputStreaming
Specified by:
write in interface DataOutput
Overrides:
write in class OutputStream
Parameters:
b - the byte array to write
Throws:
IOException - if an I/O error occurs

write

public void write(byte[] b,
                  int off,
                  int len)
           throws IOException
Description copied from interface: OutputStreaming
Writes cb bytes starting at offset of from the array ab.
Specified by:
write in interface OutputStreaming
Specified by:
write in interface DataOutput
Overrides:
write in class OutputStream
Parameters:
b - the byte array to write from
off - the offset into ab to start writing from
len - the number of bytes from ab to write
Throws:
IOException - if an I/O error occurs

flush

public void flush()
           throws IOException
Description copied from interface: OutputStreaming
Flushes this OutputStream and forces any buffered output bytes to be written.
Specified by:
flush in interface OutputStreaming
Specified by:
flush in interface Flushable
Overrides:
flush in class OutputStream
Throws:
IOException - if an I/O error occurs

close

public void close()
           throws IOException
Description copied from interface: OutputStreaming
Closes this OutputStream and releases any associated system resources.
Specified by:
close in interface OutputStreaming
Specified by:
close in interface Closeable
Overrides:
close in class OutputStream
Throws:
IOException - if an I/O error occurs

size

public int size()

writeDouble

public void writeDouble(double v)
                 throws IOException
Specified by:
writeDouble in interface DataOutput
Throws:
IOException

writeFloat

public void writeFloat(float v)
                throws IOException
Specified by:
writeFloat in interface DataOutput
Throws:
IOException

writeByte

public void writeByte(int v)
               throws IOException
Specified by:
writeByte in interface DataOutput
Throws:
IOException

writeChar

public void writeChar(int v)
               throws IOException
Specified by:
writeChar in interface DataOutput
Throws:
IOException

writeInt

public void writeInt(int v)
              throws IOException
Specified by:
writeInt in interface DataOutput
Throws:
IOException

writeShort

public void writeShort(int v)
                throws IOException
Specified by:
writeShort in interface DataOutput
Throws:
IOException

writeLong

public void writeLong(long v)
               throws IOException
Specified by:
writeLong in interface DataOutput
Throws:
IOException

writeBoolean

public void writeBoolean(boolean v)
                  throws IOException
Specified by:
writeBoolean in interface DataOutput
Throws:
IOException

writeBytes

public void writeBytes(String s)
                throws IOException
Specified by:
writeBytes in interface DataOutput
Throws:
IOException

writeChars

public void writeChars(String s)
                throws IOException
Specified by:
writeChars in interface DataOutput
Throws:
IOException

writeUTF

public void writeUTF(String s)
              throws IOException
Specified by:
writeUTF in interface DataOutput
Throws:
IOException

Skip navigation links

Oracle® Coherence Java API Reference
Release 3.6.0.0

E15725-01


Copyright © 2000, 2010, Oracle and/or its affiliates. All rights reserved.