org.blinkenlights.jid3.io
Class ID3DataOutputStream

java.lang.Object
  extended byjava.io.OutputStream
      extended byjava.io.FilterOutputStream
          extended byjava.io.DataOutputStream
              extended byorg.blinkenlights.jid3.io.ID3DataOutputStream
All Implemented Interfaces:
java.io.DataOutput

public class ID3DataOutputStream
extends java.io.DataOutputStream


Field Summary
 
Fields inherited from class java.io.DataOutputStream
written
 
Fields inherited from class java.io.FilterOutputStream
out
 
Constructor Summary
ID3DataOutputStream(java.io.OutputStream oOS)
           
 
Method Summary
 void writeBE24(int iValue)
          Writes an unsigned big-endian 24-bit value.
 void writeBE32(int iValue)
          Writes a signed big-endian 32-bit value.
 void writeBEUnsigned16(int iValue)
          Writes an unsigned big-endian 16-bit value.
 void writeID3Four(int iValue)
          Write an encoded four byte value.
 void writeUnsignedBE32(long lValue)
          Writes an unsigned big-endian 32-bit value.
 void writeUnsignedByte(int iValue)
          Write an unsigned byte value.
 
Methods inherited from class java.io.DataOutputStream
flush, size, write, write, writeBoolean, writeByte, writeBytes, writeChar, writeChars, writeDouble, writeFloat, writeInt, writeLong, writeShort, writeUTF
 
Methods inherited from class java.io.FilterOutputStream
close, write
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface java.io.DataOutput
write
 

Constructor Detail

ID3DataOutputStream

public ID3DataOutputStream(java.io.OutputStream oOS)
Method Detail

writeUnsignedByte

public void writeUnsignedByte(int iValue)
                       throws java.io.IOException
Write an unsigned byte value.

Parameters:
iValue - the unsigned byte value to be written
Throws:
java.io.IOException

writeBEUnsigned16

public void writeBEUnsigned16(int iValue)
                       throws java.io.IOException
Writes an unsigned big-endian 16-bit value. (Truncates any higher bits.)

Parameters:
iValue - the 16-bit unsigned integer value to be written
Throws:
java.io.IOException

writeBE24

public void writeBE24(int iValue)
               throws java.io.IOException
Writes an unsigned big-endian 24-bit value. (Truncates any higher bits.)

Parameters:
iValue - the 24-bit unsigned integer value to be written
Throws:
java.io.IOException

writeBE32

public void writeBE32(int iValue)
               throws java.io.IOException
Writes a signed big-endian 32-bit value.

Parameters:
iValue - the 32-bit signed integer value to be written
Throws:
java.io.IOException

writeUnsignedBE32

public void writeUnsignedBE32(long lValue)
                       throws java.io.IOException
Writes an unsigned big-endian 32-bit value.

Parameters:
lValue - the 32-bit unsigned integer value to be written
Throws:
java.io.IOException

writeID3Four

public void writeID3Four(int iValue)
                  throws java.io.IOException,
                         ID3Exception
Write an encoded four byte value. The encoding method uses only the lowest seven bits of each byte, to prevent synchronization errors in the MP3 data stream.

Throws:
java.io.IOException
ID3Exception