Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

org.hsqldb
Class DatabaseRowOutput  view DatabaseRowOutput download DatabaseRowOutput.java

java.lang.Object
  extended byjava.io.OutputStream
      extended byjava.io.FilterOutputStream
          extended byjava.io.DataOutputStream
              extended byorg.hsqldb.DatabaseRowOutput
All Implemented Interfaces:
DatabaseRowOutputInterface, java.io.DataOutput
Direct Known Subclasses:
BinaryDatabaseRowOutput, BinaryServerRowOutput, TextDatabaseRowOutput

abstract class DatabaseRowOutput
extends java.io.DataOutputStream
implements DatabaseRowOutputInterface

Base class for writing the data for a database row in different formats. Defines the methods that are independent of storage format and declares the format-dependent methods that subclasses should define.

Version:
1.7.0

Field Summary
protected  boolean skipSystemId
           
 
Fields inherited from class java.io.DataOutputStream
written
 
Fields inherited from class java.io.FilterOutputStream
out
 
Constructor Summary
DatabaseRowOutput(java.io.OutputStream out)
           
 
Method Summary
 byte[] toByteArray()
           
protected abstract  void writeBigint(java.lang.Number o)
           
protected abstract  void writeBinary(byte[] o, int t)
           
protected abstract  void writeBit(java.lang.Boolean o)
           
protected abstract  void writeChar(java.lang.String s, int t)
           
 void writeData(int l, int[] types, java.lang.Object[] data)
          This method is called to write data for a Result
 void writeData(java.lang.Object[] data, Table t)
          This method is called to write data for a table
protected abstract  void writeDate(java.sql.Date o)
           
protected abstract  void writeDecimal(java.math.BigDecimal o)
           
protected abstract  void writeFieldType(int type)
           
abstract  void writeIntData(int i)
           
protected abstract  void writeInteger(java.lang.Number o)
           
protected abstract  void writeNull(int type)
           
protected abstract  void writeOther(java.lang.Object o)
           
abstract  void writePos(int pos)
           
protected abstract  void writeReal(java.lang.Double o, int type)
           
abstract  void writeSize(int size)
           
protected abstract  void writeSmallint(java.lang.Number o)
           
abstract  void writeString(java.lang.String s)
           
protected abstract  void writeTime(java.sql.Time o)
           
protected abstract  void writeTimestamp(java.sql.Timestamp o)
           
abstract  void writeType(int type)
           
 
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
 

Field Detail

skipSystemId

protected boolean skipSystemId
Constructor Detail

DatabaseRowOutput

public DatabaseRowOutput(java.io.OutputStream out)
                  throws java.io.IOException
Method Detail

writePos

public abstract void writePos(int pos)
                       throws java.io.IOException
Specified by:
writePos in interface DatabaseRowOutputInterface

writeSize

public abstract void writeSize(int size)
                        throws java.io.IOException
Specified by:
writeSize in interface DatabaseRowOutputInterface

writeType

public abstract void writeType(int type)
                        throws java.io.IOException
Specified by:
writeType in interface DatabaseRowOutputInterface

writeIntData

public abstract void writeIntData(int i)
                           throws java.io.IOException
Specified by:
writeIntData in interface DatabaseRowOutputInterface

writeString

public abstract void writeString(java.lang.String s)
                          throws java.io.IOException
Specified by:
writeString in interface DatabaseRowOutputInterface

writeFieldType

protected abstract void writeFieldType(int type)
                                throws java.io.IOException

writeNull

protected abstract void writeNull(int type)
                           throws java.io.IOException

writeChar

protected abstract void writeChar(java.lang.String s,
                                  int t)
                           throws java.io.IOException

writeSmallint

protected abstract void writeSmallint(java.lang.Number o)
                               throws java.io.IOException,
                                      java.sql.SQLException

writeInteger

protected abstract void writeInteger(java.lang.Number o)
                              throws java.io.IOException,
                                     java.sql.SQLException

writeBigint

protected abstract void writeBigint(java.lang.Number o)
                             throws java.io.IOException,
                                    java.sql.SQLException

writeReal

protected abstract void writeReal(java.lang.Double o,
                                  int type)
                           throws java.io.IOException,
                                  java.sql.SQLException

writeDecimal

protected abstract void writeDecimal(java.math.BigDecimal o)
                              throws java.io.IOException,
                                     java.sql.SQLException

writeBit

protected abstract void writeBit(java.lang.Boolean o)
                          throws java.io.IOException,
                                 java.sql.SQLException

writeDate

protected abstract void writeDate(java.sql.Date o)
                           throws java.io.IOException,
                                  java.sql.SQLException

writeTime

protected abstract void writeTime(java.sql.Time o)
                           throws java.io.IOException,
                                  java.sql.SQLException

writeTimestamp

protected abstract void writeTimestamp(java.sql.Timestamp o)
                                throws java.io.IOException,
                                       java.sql.SQLException

writeOther

protected abstract void writeOther(java.lang.Object o)
                            throws java.io.IOException,
                                   java.sql.SQLException

writeBinary

protected abstract void writeBinary(byte[] o,
                                    int t)
                             throws java.io.IOException,
                                    java.sql.SQLException

writeData

public void writeData(java.lang.Object[] data,
                      Table t)
               throws java.io.IOException,
                      java.sql.SQLException
This method is called to write data for a table

Specified by:
writeData in interface DatabaseRowOutputInterface

writeData

public void writeData(int l,
                      int[] types,
                      java.lang.Object[] data)
               throws java.io.IOException,
                      java.sql.SQLException
This method is called to write data for a Result

Specified by:
writeData in interface DatabaseRowOutputInterface

toByteArray

public byte[] toByteArray()
                   throws java.io.IOException