text: <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
  <!--NewPage-->
  <HTML>
  <HEAD>
  <!-- Generated by javadoc (build 1.5.0) on Thu May 15 17:17:32 EDT 2008 -->
  <TITLE>
  TupleOutput (Oracle - Berkeley DB Java API)
  </TITLE>
  
  <META NAME="keywords" CONTENT="com.sleepycat.bind.tuple.TupleOutput class">
  
  <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../style.css" TITLE="Style">
  
  <SCRIPT type="text/javascript">
  function windowTitle()
  {
      parent.document.title="TupleOutput (Oracle - Berkeley DB Java API)";
  }
  </SCRIPT>
  <NOSCRIPT>
  </NOSCRIPT>
  
  </HEAD>
  
  <BODY BGCOLOR="white" onload="windowTitle();">
  
  
  <!-- ========= START OF TOP NAVBAR ======= -->
  <A NAME="navbar_top"><!-- --></A>
  <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
  <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
  <TR>
  <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
  <A NAME="navbar_top_firstrow"><!-- --></A>
  <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
    <TR ALIGN="center" VALIGN="top">
    <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
    <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
    <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
    <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="class-use/TupleOutput.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
    <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
    <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
    <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
    <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
    </TR>
  </TABLE>
  </TD>
  <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
  <b>Berkeley DB</b><br><font size="-1"> version 4.7.25</font></EM>
  </TD>
  </TR>
  
  <TR>
  <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
  &nbsp;<A HREF="../../../../com/sleepycat/bind/tuple/TupleMarshalledBinding.html" title="class in com.sleepycat.bind.tuple"><B>PREV CLASS</B></A>&nbsp;
  &nbsp;<A HREF="../../../../com/sleepycat/bind/tuple/TupleTupleBinding.html" title="class in com.sleepycat.bind.tuple"><B>NEXT CLASS</B></A></FONT></TD>
  <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
    <A HREF="../../../../index.html?com/sleepycat/bind/tuple/TupleOutput.html" target="_top"><B>FRAMES</B></A>  &nbsp;
  &nbsp;<A HREF="TupleOutput.html" target="_top"><B>NO FRAMES</B></A>  &nbsp;
  &nbsp;<SCRIPT type="text/javascript">
    <!--
    if(window==top) {
      document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
    }
    //-->
  </SCRIPT>
  <NOSCRIPT>
    <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
  </NOSCRIPT>
  
  
  </FONT></TD>
  </TR>
  <TR>
  <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
    SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;<A HREF="#fields_inherited_from_class_com.sleepycat.util.FastOutputStream">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
  <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
  DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
  </TR>
  </TABLE>
  <A NAME="skip-navbar_top"></A>
  <!-- ========= END OF TOP NAVBAR ========= -->
  
  <HR>
  <!-- ======== START OF CLASS DATA ======== -->
  <H2>
  <FONT SIZE="-1">
  com.sleepycat.bind.tuple</FONT>
  <BR>
  Class TupleOutput</H2>
  <PRE>
  <A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Object.html" title="class or interface in java.lang">java.lang.Object</A>
    <IMG SRC="../../../../resources/inherit.gif" ALT="extended by "><A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/io/OutputStream.html" title="class or interface in java.io">java.io.OutputStream</A>
        <IMG SRC="../../../../resources/inherit.gif" ALT="extended by "><A HREF="../../../../com/sleepycat/util/FastOutputStream.html" title="class in com.sleepycat.util">com.sleepycat.util.FastOutputStream</A>
            <IMG SRC="../../../../resources/inherit.gif" ALT="extended by "><B>com.sleepycat.bind.tuple.TupleOutput</B>
  </PRE>
  <DL>
  <DT><B>All Implemented Interfaces:</B> <DD><A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/io/Closeable.html" title="class or interface in java.io">Closeable</A>, <A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/io/Flushable.html" title="class or interface in java.io">Flushable</A></DD>
  </DL>
  <HR>
  <DL>
  <DT><PRE>public class <B>TupleOutput</B><DT>extends <A HREF="../../../../com/sleepycat/util/FastOutputStream.html" title="class in com.sleepycat.util">FastOutputStream</A></DL>
  </PRE>
  
  <P>
  An <code>OutputStream</code> with <code>DataOutput</code>-like methods for
   writing tuple fields.  It is used by <code>TupleBinding</code>.
  
   <p>This class has many methods that have the same signatures as methods in
   the <A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/io/DataOutput.html" title="class or interface in java.io"><CODE>DataOutput</CODE></A> interface.  The reason this class does not
   implement <A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/io/DataOutput.html" title="class or interface in java.io"><CODE>DataOutput</CODE></A> is because it would break the interface
   contract for those methods because of data format differences.</p>
  
   <p>Signed numbers are stored in the buffer in MSB (most significant byte
   first) order with their sign bit (high-order bit) inverted to cause negative
   numbers to be sorted first when comparing values as unsigned byte arrays,
   as done in a database.  Unsigned numbers, including characters, are stored
   in MSB order with no change to their sign bit.  BigInteger values are stored
   with a preceding length having the same sign as the value.</p>
  
   <p>Strings and character arrays are stored either as a fixed length array of
   unicode characters, where the length must be known by the application, or as
   a null-terminated UTF byte array.</p>
   <ul>
   <li>Null strings are UTF encoded as { 0xFF }, which is not allowed in a
   standard UTF encoding.  This allows null strings, as distinct from empty or
   zero length strings, to be represented in a tuple.  Using the default
   comparator, null strings will be ordered last.</li>
   <li>Zero (0x0000) character values are UTF encoded as non-zero values, and
   therefore embedded zeros in the string are supported.  The sequence { 0xC0,
   0x80 } is used to encode a zero character.  This UTF encoding is the same
   one used by native Java UTF libraries.  However, this encoding of zero does
   impact the lexicographical ordering, and zeros will not be sorted first (the
   natural order) or last.  For all character values other than zero, the
   default UTF byte ordering is the same as the Unicode lexicographical
   character ordering.</li>
   </ul>
  
   <p>Floats and doubles are stored using two different representations: sorted
   representation and integer-bit (IEEE 754) representation.  If you use
   negative floating point numbers in a key, you should use sorted
   representation; alternatively you may use integer-bit representation but you
   will need to implement and configure a custom comparator to get correct
   numeric ordering for negative numbers.</p>
  
   <p>To use sorted representation use this set of methods:</p>
   <ul>
   <li><A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html#writeSortedFloat(float)"><CODE>writeSortedFloat(float)</CODE></A></li>
   <li><A HREF="../../../../com/sleepycat/bind/tuple/TupleInput.html#readSortedFloat()"><CODE>TupleInput.readSortedFloat()</CODE></A></li>
   <li><A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html#writeSortedDouble(double)"><CODE>writeSortedDouble(double)</CODE></A></li>
   <li><A HREF="../../../../com/sleepycat/bind/tuple/TupleInput.html#readSortedDouble()"><CODE>TupleInput.readSortedDouble()</CODE></A></li>
   </ul>
  
   <p>To use integer-bit representation use this set of methods:</p>
   <ul>
   <li><A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html#writeFloat(float)"><CODE>writeFloat(float)</CODE></A></li>
   <li><A HREF="../../../../com/sleepycat/bind/tuple/TupleInput.html#readFloat()"><CODE>TupleInput.readFloat()</CODE></A></li>
   <li><A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html#writeDouble(double)"><CODE>writeDouble(double)</CODE></A></li>
   <li><A HREF="../../../../com/sleepycat/bind/tuple/TupleInput.html#readDouble()"><CODE>TupleInput.readDouble()</CODE></A></li>
   </ul>
  <P>
  
  <P>
  <HR>
  
  <P>
  <!-- =========== FIELD SUMMARY =========== -->
  
  <A NAME="field_summary"><!-- --></A>
  <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
  <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
  <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
  <B>Field Summary</B></FONT></TH>
  </TR>
  </TABLE>
  &nbsp;<A NAME="fields_inherited_from_class_com.sleepycat.util.FastOutputStream"><!-- --></A>
  <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
  <TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
  <TH ALIGN="left"><B>Fields inherited from class com.sleepycat.util.<A HREF="../../../../com/sleepycat/util/FastOutputStream.html" title="class in com.sleepycat.util">FastOutputStream</A></B></TH>
  </TR>
  <TR BGCOLOR="white" CLASS="TableRowColor">
  <TD><CODE><A HREF="../../../../com/sleepycat/util/FastOutputStream.html#DEFAULT_BUMP_SIZE">DEFAULT_BUMP_SIZE</A>, <A HREF="../../../../com/sleepycat/util/FastOutputStream.html#DEFAULT_INIT_SIZE">DEFAULT_INIT_SIZE</A></CODE></TD>
  </TR>
  </TABLE>
  &nbsp;
  <!-- ======== CONSTRUCTOR SUMMARY ======== -->
  
  <A NAME="constructor_summary"><!-- --></A>
  <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
  <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
  <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
  <B>Constructor Summary</B></FONT></TH>
  </TR>
  <TR BGCOLOR="white" CLASS="TableRowColor">
  <TD><CODE><B><A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html#TupleOutput()">TupleOutput</A></B>()</CODE>
  
  <BR>
  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Creates a tuple output object for writing a byte array of tuple data.</TD>
  </TR>
  <TR BGCOLOR="white" CLASS="TableRowColor">
  <TD><CODE><B><A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html#TupleOutput(byte[])">TupleOutput</A></B>(byte[]&nbsp;buffer)</CODE>
  
  <BR>
  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Creates a tuple output object for writing a byte array of tuple data,
   using a given buffer.</TD>
  </TR>
  </TABLE>
  &nbsp;
  <!-- ========== METHOD SUMMARY =========== -->
  
  <A NAME="method_summary"><!-- --></A>
  <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
  <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
  <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
  <B>Method Summary</B></FONT></TH>
  </TR>
  <TR BGCOLOR="white" CLASS="TableRowColor">
  <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
  <CODE>static&nbsp;int</CODE></FONT></TD>
  <TD><CODE><B><A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html#getBigIntegerByteLength(java.math.BigInteger)">getBigIntegerByteLength</A></B>(<A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/math/BigInteger.html" title="class or interface in java.math">BigInteger</A>&nbsp;val)</CODE>
  
  <BR>
  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the byte length of a given <code>BigInteger</code> value.</TD>
  </TR>
  <TR BGCOLOR="white" CLASS="TableRowColor">
  <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
  <CODE>&nbsp;<A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html" title="class in com.sleepycat.bind.tuple">TupleOutput</A></CODE></FONT></TD>
  <TD><CODE><B><A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html#writeBigInteger(java.math.BigInteger)">writeBigInteger</A></B>(<A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/math/BigInteger.html" title="class or interface in java.math">BigInteger</A>&nbsp;val)</CODE>
  
  <BR>
  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Writes a <code>BigInteger</code>.</TD>
  </TR>
  <TR BGCOLOR="white" CLASS="TableRowColor">
  <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
  <CODE>&nbsp;<A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html" title="class in com.sleepycat.bind.tuple">TupleOutput</A></CODE></FONT></TD>
  <TD><CODE><B><A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html#writeBoolean(boolean)">writeBoolean</A></B>(boolean&nbsp;val)</CODE>
  
  <BR>
  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Writes a boolean (one byte) unsigned value to the buffer, writing one
   if the value is true and zero if it is false.</TD>
  </TR>
  <TR BGCOLOR="white" CLASS="TableRowColor">
  <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
  <CODE>&nbsp;<A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html" title="class in com.sleepycat.bind.tuple">TupleOutput</A></CODE></FONT></TD>
  <TD><CODE><B><A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html#writeByte(int)">writeByte</A></B>(int&nbsp;val)</CODE>
  
  <BR>
  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Writes an signed byte (one byte) value to the buffer.</TD>
  </TR>
  <TR BGCOLOR="white" CLASS="TableRowColor">
  <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
  <CODE>&nbsp;<A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html" title="class in com.sleepycat.bind.tuple">TupleOutput</A></CODE></FONT></TD>
  <TD><CODE><B><A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html#writeBytes(char[])">writeBytes</A></B>(char[]&nbsp;chars)</CODE>
  
  <BR>
  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Writes the specified bytes to the buffer, converting each character to
   an unsigned byte value.</TD>
  </TR>
  <TR BGCOLOR="white" CLASS="TableRowColor">
  <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
  <CODE>&nbsp;<A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html" title="class in com.sleepycat.bind.tuple">TupleOutput</A></CODE></FONT></TD>
  <TD><CODE><B><A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html#writeBytes(java.lang.String)">writeBytes</A></B>(<A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A>&nbsp;val)</CODE>
  
  <BR>
  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Writes the specified bytes to the buffer, converting each character to
   an unsigned byte value.</TD>
  </TR>
  <TR BGCOLOR="white" CLASS="TableRowColor">
  <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
  <CODE>&nbsp;<A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html" title="class in com.sleepycat.bind.tuple">TupleOutput</A></CODE></FONT></TD>
  <TD><CODE><B><A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html#writeChar(int)">writeChar</A></B>(int&nbsp;val)</CODE>
  
  <BR>
  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Writes a char (two byte) unsigned value to the buffer.</TD>
  </TR>
  <TR BGCOLOR="white" CLASS="TableRowColor">
  <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
  <CODE>&nbsp;<A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html" title="class in com.sleepycat.bind.tuple">TupleOutput</A></CODE></FONT></TD>
  <TD><CODE><B><A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html#writeChars(char[])">writeChars</A></B>(char[]&nbsp;chars)</CODE>
  
  <BR>
  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Writes the specified characters to the buffer, converting each character
   to a two byte unsigned value.</TD>
  </TR>
  <TR BGCOLOR="white" CLASS="TableRowColor">
  <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
  <CODE>&nbsp;<A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html" title="class in com.sleepycat.bind.tuple">TupleOutput</A></CODE></FONT></TD>
  <TD><CODE><B><A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html#writeChars(java.lang.String)">writeChars</A></B>(<A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A>&nbsp;val)</CODE>
  
  <BR>
  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Writes the specified characters to the buffer, converting each character
   to a two byte unsigned value.</TD>
  </TR>
  <TR BGCOLOR="white" CLASS="TableRowColor">
  <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
  <CODE>&nbsp;<A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html" title="class in com.sleepycat.bind.tuple">TupleOutput</A></CODE></FONT></TD>
  <TD><CODE><B><A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html#writeDouble(double)">writeDouble</A></B>(double&nbsp;val)</CODE>
  
  <BR>
  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Writes an signed double (eight byte) value to the buffer.</TD>
  </TR>
  <TR BGCOLOR="white" CLASS="TableRowColor">
  <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
  <CODE>&nbsp;<A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html" title="class in com.sleepycat.bind.tuple">TupleOutput</A></CODE></FONT></TD>
  <TD><CODE><B><A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html#writeFloat(float)">writeFloat</A></B>(float&nbsp;val)</CODE>
  
  <BR>
  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Writes an signed float (four byte) value to the buffer.</TD>
  </TR>
  <TR BGCOLOR="white" CLASS="TableRowColor">
  <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
  <CODE>&nbsp;<A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html" title="class in com.sleepycat.bind.tuple">TupleOutput</A></CODE></FONT></TD>
  <TD><CODE><B><A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html#writeInt(int)">writeInt</A></B>(int&nbsp;val)</CODE>
  
  <BR>
  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Writes an signed int (four byte) value to the buffer.</TD>
  </TR>
  <TR BGCOLOR="white" CLASS="TableRowColor">
  <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
  <CODE>&nbsp;<A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html" title="class in com.sleepycat.bind.tuple">TupleOutput</A></CODE></FONT></TD>
  <TD><CODE><B><A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html#writeLong(long)">writeLong</A></B>(long&nbsp;val)</CODE>
  
  <BR>
  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Writes an signed long (eight byte) value to the buffer.</TD>
  </TR>
  <TR BGCOLOR="white" CLASS="TableRowColor">
  <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
  <CODE>&nbsp;void</CODE></FONT></TD>
  <TD><CODE><B><A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html#writePackedInt(int)">writePackedInt</A></B>(int&nbsp;val)</CODE>
  
  <BR>
  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Writes a packed integer.</TD>
  </TR>
  <TR BGCOLOR="white" CLASS="TableRowColor">
  <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
  <CODE>&nbsp;void</CODE></FONT></TD>
  <TD><CODE><B><A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html#writePackedLong(long)">writePackedLong</A></B>(long&nbsp;val)</CODE>
  
  <BR>
  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Writes a packed long integer.</TD>
  </TR>
  <TR BGCOLOR="white" CLASS="TableRowColor">
  <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
  <CODE>&nbsp;<A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html" title="class in com.sleepycat.bind.tuple">TupleOutput</A></CODE></FONT></TD>
  <TD><CODE><B><A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html#writeShort(int)">writeShort</A></B>(int&nbsp;val)</CODE>
  
  <BR>
  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Writes an signed short (two byte) value to the buffer.</TD>
  </TR>
  <TR BGCOLOR="white" CLASS="TableRowColor">
  <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
  <CODE>&nbsp;<A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html" title="class in com.sleepycat.bind.tuple">TupleOutput</A></CODE></FONT></TD>
  <TD><CODE><B><A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html#writeSortedDouble(double)">writeSortedDouble</A></B>(double&nbsp;val)</CODE>
  
  <BR>
  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Writes a signed double (eight byte) value to the buffer, with support
   for correct default sorting of all values.</TD>
  </TR>
  <TR BGCOLOR="white" CLASS="TableRowColor">
  <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
  <CODE>&nbsp;<A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html" title="class in com.sleepycat.bind.tuple">TupleOutput</A></CODE></FONT></TD>
  <TD><CODE><B><A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html#writeSortedFloat(float)">writeSortedFloat</A></B>(float&nbsp;val)</CODE>
  
  <BR>
  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Writes a signed float (four byte) value to the buffer, with support for
   correct default sorting of all values.</TD>
  </TR>
  <TR BGCOLOR="white" CLASS="TableRowColor">
  <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
  <CODE>&nbsp;<A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html" title="class in com.sleepycat.bind.tuple">TupleOutput</A></CODE></FONT></TD>
  <TD><CODE><B><A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html#writeString(char[])">writeString</A></B>(char[]&nbsp;chars)</CODE>
  
  <BR>
  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Writes the specified characters to the buffer, converting each character
   to UTF format.</TD>
  </TR>
  <TR BGCOLOR="white" CLASS="TableRowColor">
  <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
  <CODE>&nbsp;<A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html" title="class in com.sleepycat.bind.tuple">TupleOutput</A></CODE></FONT></TD>
  <TD><CODE><B><A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html#writeString(java.lang.String)">writeString</A></B>(<A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A>&nbsp;val)</CODE>
  
  <BR>
  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Writes the specified characters to the buffer, converting each character
   to UTF format, and adding a null terminator byte.</TD>
  </TR>
  <TR BGCOLOR="white" CLASS="TableRowColor">
  <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
  <CODE>&nbsp;<A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html" title="class in com.sleepycat.bind.tuple">TupleOutput</A></CODE></FONT></TD>
  <TD><CODE><B><A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html#writeUnsignedByte(int)">writeUnsignedByte</A></B>(int&nbsp;val)</CODE>
  
  <BR>
  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Writes an unsigned byte (one byte) value to the buffer.</TD>
  </TR>
  <TR BGCOLOR="white" CLASS="TableRowColor">
  <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
  <CODE>&nbsp;<A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html" title="class in com.sleepycat.bind.tuple">TupleOutput</A></CODE></FONT></TD>
  <TD><CODE><B><A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html#writeUnsignedInt(long)">writeUnsignedInt</A></B>(long&nbsp;val)</CODE>
  
  <BR>
  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Writes an unsigned int (four byte) value to the buffer.</TD>
  </TR>
  <TR BGCOLOR="white" CLASS="TableRowColor">
  <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
  <CODE>&nbsp;<A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html" title="class in com.sleepycat.bind.tuple">TupleOutput</A></CODE></FONT></TD>
  <TD><CODE><B><A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html#writeUnsignedShort(int)">writeUnsignedShort</A></B>(int&nbsp;val)</CODE>
  
  <BR>
  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Writes an unsigned short (two byte) value to the buffer.</TD>
  </TR>
  </TABLE>
  &nbsp;<A NAME="methods_inherited_from_class_com.sleepycat.util.FastOutputStream"><!-- --></A>
  <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
  <TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
  <TH ALIGN="left"><B>Methods inherited from class com.sleepycat.util.<A HREF="../../../../com/sleepycat/util/FastOutputStream.html" title="class in com.sleepycat.util">FastOutputStream</A></B></TH>
  </TR>
  <TR BGCOLOR="white" CLASS="TableRowColor">
  <TD><CODE><A HREF="../../../../com/sleepycat/util/FastOutputStream.html#addSize(int)">addSize</A>, <A HREF="../../../../com/sleepycat/util/FastOutputStream.html#getBufferBytes()">getBufferBytes</A>, <A HREF="../../../../com/sleepycat/util/FastOutputStream.html#getBufferLength()">getBufferLength</A>, <A HREF="../../../../com/sleepycat/util/FastOutputStream.html#getBufferOffset()">getBufferOffset</A>, <A HREF="../../../../com/sleepycat/util/FastOutputStream.html#makeSpace(int)">makeSpace</A>, <A HREF="../../../../com/sleepycat/util/FastOutputStream.html#reset()">reset</A>, <A HREF="../../../../com/sleepycat/util/FastOutputStream.html#size()">size</A>, <A HREF="../../../../com/sleepycat/util/FastOutputStream.html#toByteArray()">toByteArray</A>, <A HREF="../../../../com/sleepycat/util/FastOutputStream.html#toString()">toString</A>, <A HREF="../../../../com/sleepycat/util/FastOutputStream.html#toString(java.lang.String)">toString</A>, <A HREF="../../../../com/sleepycat/util/FastOutputStream.html#write(byte[])">write</A>, <A HREF="../../../../com/sleepycat/util/FastOutputStream.html#write(byte[], int, int)">write</A>, <A HREF="../../../../com/sleepycat/util/FastOutputStream.html#write(int)">write</A>, <A HREF="../../../../com/sleepycat/util/FastOutputStream.html#writeFast(byte[])">writeFast</A>, <A HREF="../../../../com/sleepycat/util/FastOutputStream.html#writeFast(byte[], int, int)">writeFast</A>, <A HREF="../../../../com/sleepycat/util/FastOutputStream.html#writeFast(int)">writeFast</A>, <A HREF="../../../../com/sleepycat/util/FastOutputStream.html#writeTo(java.io.OutputStream)">writeTo</A></CODE></TD>
  </TR>
  </TABLE>
  &nbsp;<A NAME="methods_inherited_from_class_java.io.OutputStream"><!-- --></A>
  <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
  <TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
  <TH ALIGN="left"><B>Methods inherited from class java.io.<A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/io/OutputStream.html" title="class or interface in java.io">OutputStream</A></B></TH>
  </TR>
  <TR BGCOLOR="white" CLASS="TableRowColor">
  <TD><CODE><A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/io/OutputStream.html#close()" title="class or interface in java.io">close</A>, <A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/io/OutputStream.html#flush()" title="class or interface in java.io">flush</A></CODE></TD>
  </TR>
  </TABLE>
  &nbsp;<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A>
  <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
  <TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
  <TH ALIGN="left"><B>Methods inherited from class java.lang.<A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Object.html" title="class or interface in java.lang">Object</A></B></TH>
  </TR>
  <TR BGCOLOR="white" CLASS="TableRowColor">
  <TD><CODE><A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Object.html#clone()" title="class or interface in java.lang">clone</A>, <A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Object.html#equals(java.lang.Object)" title="class or interface in java.lang">equals</A>, <A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Object.html#finalize()" title="class or interface in java.lang">finalize</A>, <A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Object.html#getClass()" title="class or interface in java.lang">getClass</A>, <A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Object.html#hashCode()" title="class or interface in java.lang">hashCode</A>, <A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Object.html#notify()" title="class or interface in java.lang">notify</A>, <A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Object.html#notifyAll()" title="class or interface in java.lang">notifyAll</A>, <A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Object.html#wait()" title="class or interface in java.lang">wait</A>, <A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Object.html#wait(long)" title="class or interface in java.lang">wait</A>, <A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Object.html#wait(long, int)" title="class or interface in java.lang">wait</A></CODE></TD>
  </TR>
  </TABLE>
  &nbsp;
  <P>
  
  <!-- ========= CONSTRUCTOR DETAIL ======== -->
  
  <A NAME="constructor_detail"><!-- --></A>
  <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
  <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
  <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
  <B>Constructor Detail</B></FONT></TH>
  </TR>
  </TABLE>
  
  <A NAME="TupleOutput()"><!-- --></A><H3>
  TupleOutput</H3>
  <PRE>
  public <B>TupleOutput</B>()</PRE>
  <DL>
  <DD>Creates a tuple output object for writing a byte array of tuple data.
  <P>
  </DL>
  <HR>
  
  <A NAME="TupleOutput(byte[])"><!-- --></A><H3>
  TupleOutput</H3>
  <PRE>
  public <B>TupleOutput</B>(byte[]&nbsp;buffer)</PRE>
  <DL>
  <DD>Creates a tuple output object for writing a byte array of tuple data,
   using a given buffer.  A new buffer will be allocated only if the number
   of bytes needed is greater than the length of this buffer.  A reference
   to the byte array will be kept by this object and therefore the byte
   array should not be modified while this object is in use.
  <P>
  <DL>
  <DT><B>Parameters:</B><DD><CODE>buffer</CODE> - is the byte array to use as the buffer.</DL>
  </DL>
  
  <!-- ============ METHOD DETAIL ========== -->
  
  <A NAME="method_detail"><!-- --></A>
  <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
  <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
  <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
  <B>Method Detail</B></FONT></TH>
  </TR>
  </TABLE>
  
  <A NAME="writeBytes(java.lang.String)"><!-- --></A><H3>
  writeBytes</H3>
  <PRE>
  public final <A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html" title="class in com.sleepycat.bind.tuple">TupleOutput</A> <B>writeBytes</B>(<A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A>&nbsp;val)</PRE>
  <DL>
  <DD>Writes the specified bytes to the buffer, converting each character to
   an unsigned byte value.
   Writes values that can be read using <A HREF="../../../../com/sleepycat/bind/tuple/TupleInput.html#readBytes(int)"><CODE>TupleInput.readBytes(int)</CODE></A>.
   Only characters with values below 0x100 may be written using this
   method, since the high-order 8 bits of all characters are discarded.
  <P>
  <DD><DL>
  <DT><B>Parameters:</B><DD><CODE>val</CODE> - is the string containing the values to be written.
  <DT><B>Returns:</B><DD>this tuple output object.
  <DT><B>Throws:</B>
  <DD><CODE><A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/NullPointerException.html" title="class or interface in java.lang">NullPointerException</A></CODE> - if the val parameter is null.</DL>
  </DD>
  </DL>
  <HR>
  
  <A NAME="writeChars(java.lang.String)"><!-- --></A><H3>
  writeChars</H3>
  <PRE>
  public final <A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html" title="class in com.sleepycat.bind.tuple">TupleOutput</A> <B>writeChars</B>(<A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A>&nbsp;val)</PRE>
  <DL>
  <DD>Writes the specified characters to the buffer, converting each character
   to a two byte unsigned value.
   Writes values that can be read using <A HREF="../../../../com/sleepycat/bind/tuple/TupleInput.html#readChars(int)"><CODE>TupleInput.readChars(int)</CODE></A>.
  <P>
  <DD><DL>
  <DT><B>Parameters:</B><DD><CODE>val</CODE> - is the string containing the characters to be written.
  <DT><B>Returns:</B><DD>this tuple output object.
  <DT><B>Throws:</B>
  <DD><CODE><A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/NullPointerException.html" title="class or interface in java.lang">NullPointerException</A></CODE> - if the val parameter is null.</DL>
  </DD>
  </DL>
  <HR>
  
  <A NAME="writeString(java.lang.String)"><!-- --></A><H3>
  writeString</H3>
  <PRE>
  public final <A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html" title="class in com.sleepycat.bind.tuple">TupleOutput</A> <B>writeString</B>(<A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A>&nbsp;val)</PRE>
  <DL>
  <DD>Writes the specified characters to the buffer, converting each character
   to UTF format, and adding a null terminator byte.
   Note that zero (0x0000) character values are encoded as non-zero values
   and a null String parameter is encoded as 0xFF.
   Writes values that can be read using <A HREF="../../../../com/sleepycat/bind/tuple/TupleInput.html#readString()"><CODE>TupleInput.readString()</CODE></A>.
  <P>
  <DD><DL>
  <DT><B>Parameters:</B><DD><CODE>val</CODE> - is the string containing the characters to be written.
  <DT><B>Returns:</B><DD>this tuple output object.</DL>
  </DD>
  </DL>
  <HR>
  
  <A NAME="writeChar(int)"><!-- --></A><H3>
  writeChar</H3>
  <PRE>
  public final <A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html" title="class in com.sleepycat.bind.tuple">TupleOutput</A> <B>writeChar</B>(int&nbsp;val)</PRE>
  <DL>
  <DD>Writes a char (two byte) unsigned value to the buffer.
   Writes values that can be read using <A HREF="../../../../com/sleepycat/bind/tuple/TupleInput.html#readChar()"><CODE>TupleInput.readChar()</CODE></A>.
  <P>
  <DD><DL>
  <DT><B>Parameters:</B><DD><CODE>val</CODE> - is the value to write to the buffer.
  <DT><B>Returns:</B><DD>this tuple output object.</DL>
  </DD>
  </DL>
  <HR>
  
  <A NAME="writeBoolean(boolean)"><!-- --></A><H3>
  writeBoolean</H3>
  <PRE>
  public final <A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html" title="class in com.sleepycat.bind.tuple">TupleOutput</A> <B>writeBoolean</B>(boolean&nbsp;val)</PRE>
  <DL>
  <DD>Writes a boolean (one byte) unsigned value to the buffer, writing one
   if the value is true and zero if it is false.
   Writes values that can be read using <A HREF="../../../../com/sleepycat/bind/tuple/TupleInput.html#readBoolean()"><CODE>TupleInput.readBoolean()</CODE></A>.
  <P>
  <DD><DL>
  <DT><B>Parameters:</B><DD><CODE>val</CODE> - is the value to write to the buffer.
  <DT><B>Returns:</B><DD>this tuple output object.</DL>
  </DD>
  </DL>
  <HR>
  
  <A NAME="writeByte(int)"><!-- --></A><H3>
  writeByte</H3>
  <PRE>
  public final <A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html" title="class in com.sleepycat.bind.tuple">TupleOutput</A> <B>writeByte</B>(int&nbsp;val)</PRE>
  <DL>
  <DD>Writes an signed byte (one byte) value to the buffer.
   Writes values that can be read using <A HREF="../../../../com/sleepycat/bind/tuple/TupleInput.html#readByte()"><CODE>TupleInput.readByte()</CODE></A>.
  <P>
  <DD><DL>
  <DT><B>Parameters:</B><DD><CODE>val</CODE> - is the value to write to the buffer.
  <DT><B>Returns:</B><DD>this tuple output object.</DL>
  </DD>
  </DL>
  <HR>
  
  <A NAME="writeShort(int)"><!-- --></A><H3>
  writeShort</H3>
  <PRE>
  public final <A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html" title="class in com.sleepycat.bind.tuple">TupleOutput</A> <B>writeShort</B>(int&nbsp;val)</PRE>
  <DL>
  <DD>Writes an signed short (two byte) value to the buffer.
   Writes values that can be read using <A HREF="../../../../com/sleepycat/bind/tuple/TupleInput.html#readShort()"><CODE>TupleInput.readShort()</CODE></A>.
  <P>
  <DD><DL>
  <DT><B>Parameters:</B><DD><CODE>val</CODE> - is the value to write to the buffer.
  <DT><B>Returns:</B><DD>this tuple output object.</DL>
  </DD>
  </DL>
  <HR>
  
  <A NAME="writeInt(int)"><!-- --></A><H3>
  writeInt</H3>
  <PRE>
  public final <A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html" title="class in com.sleepycat.bind.tuple">TupleOutput</A> <B>writeInt</B>(int&nbsp;val)</PRE>
  <DL>
  <DD>Writes an signed int (four byte) value to the buffer.
   Writes values that can be read using <A HREF="../../../../com/sleepycat/bind/tuple/TupleInput.html#readInt()"><CODE>TupleInput.readInt()</CODE></A>.
  <P>
  <DD><DL>
  <DT><B>Parameters:</B><DD><CODE>val</CODE> - is the value to write to the buffer.
  <DT><B>Returns:</B><DD>this tuple output object.</DL>
  </DD>
  </DL>
  <HR>
  
  <A NAME="writeLong(long)"><!-- --></A><H3>
  writeLong</H3>
  <PRE>
  public final <A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html" title="class in com.sleepycat.bind.tuple">TupleOutput</A> <B>writeLong</B>(long&nbsp;val)</PRE>
  <DL>
  <DD>Writes an signed long (eight byte) value to the buffer.
   Writes values that can be read using <A HREF="../../../../com/sleepycat/bind/tuple/TupleInput.html#readLong()"><CODE>TupleInput.readLong()</CODE></A>.
  <P>
  <DD><DL>
  <DT><B>Parameters:</B><DD><CODE>val</CODE> - is the value to write to the buffer.
  <DT><B>Returns:</B><DD>this tuple output object.</DL>
  </DD>
  </DL>
  <HR>
  
  <A NAME="writeFloat(float)"><!-- --></A><H3>
  writeFloat</H3>
  <PRE>
  public final <A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html" title="class in com.sleepycat.bind.tuple">TupleOutput</A> <B>writeFloat</B>(float&nbsp;val)</PRE>
  <DL>
  <DD>Writes an signed float (four byte) value to the buffer.
   Writes values that can be read using <A HREF="../../../../com/sleepycat/bind/tuple/TupleInput.html#readFloat()"><CODE>TupleInput.readFloat()</CODE></A>.
   <code>Float.floatToIntBits</code> is used to convert the signed float
   value.
  
   <p><em>Note:</em> This method produces byte array values that by default
   (without a custom comparator) do <em>not</em> sort correctly for
   negative values.  Only non-negative values are sorted correctly by
   default.  To sort all values correctly by default, use <A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html#writeSortedFloat(float)"><CODE>writeSortedFloat(float)</CODE></A>.</p>
  <P>
  <DD><DL>
  <DT><B>Parameters:</B><DD><CODE>val</CODE> - is the value to write to the buffer.
  <DT><B>Returns:</B><DD>this tuple output object.</DL>
  </DD>
  </DL>
  <HR>
  
  <A NAME="writeDouble(double)"><!-- --></A><H3>
  writeDouble</H3>
  <PRE>
  public final <A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html" title="class in com.sleepycat.bind.tuple">TupleOutput</A> <B>writeDouble</B>(double&nbsp;val)</PRE>
  <DL>
  <DD>Writes an signed double (eight byte) value to the buffer.
   Writes values that can be read using <A HREF="../../../../com/sleepycat/bind/tuple/TupleInput.html#readDouble()"><CODE>TupleInput.readDouble()</CODE></A>.
   <code>Double.doubleToLongBits</code> is used to convert the signed
   double value.
  
   <p><em>Note:</em> This method produces byte array values that by default
   (without a custom comparator) do <em>not</em> sort correctly for
   negative values.  Only non-negative values are sorted correctly by
   default.  To sort all values correctly by default, use <A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html#writeSortedDouble(double)"><CODE>writeSortedDouble(double)</CODE></A>.</p>
  <P>
  <DD><DL>
  <DT><B>Parameters:</B><DD><CODE>val</CODE> - is the value to write to the buffer.
  <DT><B>Returns:</B><DD>this tuple output object.</DL>
  </DD>
  </DL>
  <HR>
  
  <A NAME="writeSortedFloat(float)"><!-- --></A><H3>
  writeSortedFloat</H3>
  <PRE>
  public final <A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html" title="class in com.sleepycat.bind.tuple">TupleOutput</A> <B>writeSortedFloat</B>(float&nbsp;val)</PRE>
  <DL>
  <DD>Writes a signed float (four byte) value to the buffer, with support for
   correct default sorting of all values.
   Writes values that can be read using <A HREF="../../../../com/sleepycat/bind/tuple/TupleInput.html#readSortedFloat()"><CODE>TupleInput.readSortedFloat()</CODE></A>.
  
   <p><code>Float.floatToIntBits</code> and the following bit manipulations
   are used to convert the signed float value to a representation that is
   sorted correctly by default.</p>
   <pre>
    int intVal = Float.floatToIntBits(val);
    intVal ^= (intVal &lt; 0) ? 0xffffffff : 0x80000000;
   </pre>
  <P>
  <DD><DL>
  <DT><B>Parameters:</B><DD><CODE>val</CODE> - is the value to write to the buffer.
  <DT><B>Returns:</B><DD>this tuple output object.</DL>
  </DD>
  </DL>
  <HR>
  
  <A NAME="writeSortedDouble(double)"><!-- --></A><H3>
  writeSortedDouble</H3>
  <PRE>
  public final <A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html" title="class in com.sleepycat.bind.tuple">TupleOutput</A> <B>writeSortedDouble</B>(double&nbsp;val)</PRE>
  <DL>
  <DD>Writes a signed double (eight byte) value to the buffer, with support
   for correct default sorting of all values.
   Writes values that can be read using <A HREF="../../../../com/sleepycat/bind/tuple/TupleInput.html#readSortedDouble()"><CODE>TupleInput.readSortedDouble()</CODE></A>.
  
   <p><code>Float.doubleToLongBits</code> and the following bit
   manipulations are used to convert the signed double value to a
   representation that is sorted correctly by default.</p>
   <pre>
    long longVal = Double.doubleToLongBits(val);
    longVal ^= (longVal &lt; 0) ? 0xffffffffffffffffL : 0x8000000000000000L;
   </pre>
  <P>
  <DD><DL>
  <DT><B>Parameters:</B><DD><CODE>val</CODE> - is the value to write to the buffer.
  <DT><B>Returns:</B><DD>this tuple output object.</DL>
  </DD>
  </DL>
  <HR>
  
  <A NAME="writeBytes(char[])"><!-- --></A><H3>
  writeBytes</H3>
  <PRE>
  public final <A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html" title="class in com.sleepycat.bind.tuple">TupleOutput</A> <B>writeBytes</B>(char[]&nbsp;chars)</PRE>
  <DL>
  <DD>Writes the specified bytes to the buffer, converting each character to
   an unsigned byte value.
   Writes values that can be read using <A HREF="../../../../com/sleepycat/bind/tuple/TupleInput.html#readBytes(int)"><CODE>TupleInput.readBytes(int)</CODE></A>.
   Only characters with values below 0x100 may be written using this
   method, since the high-order 8 bits of all characters are discarded.
  <P>
  <DD><DL>
  <DT><B>Parameters:</B><DD><CODE>chars</CODE> - is the array of values to be written.
  <DT><B>Returns:</B><DD>this tuple output object.
  <DT><B>Throws:</B>
  <DD><CODE><A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/NullPointerException.html" title="class or interface in java.lang">NullPointerException</A></CODE> - if the chars parameter is null.</DL>
  </DD>
  </DL>
  <HR>
  
  <A NAME="writeChars(char[])"><!-- --></A><H3>
  writeChars</H3>
  <PRE>
  public final <A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html" title="class in com.sleepycat.bind.tuple">TupleOutput</A> <B>writeChars</B>(char[]&nbsp;chars)</PRE>
  <DL>
  <DD>Writes the specified characters to the buffer, converting each character
   to a two byte unsigned value.
   Writes values that can be read using <A HREF="../../../../com/sleepycat/bind/tuple/TupleInput.html#readChars(int)"><CODE>TupleInput.readChars(int)</CODE></A>.
  <P>
  <DD><DL>
  <DT><B>Parameters:</B><DD><CODE>chars</CODE> - is the array of characters to be written.
  <DT><B>Returns:</B><DD>this tuple output object.
  <DT><B>Throws:</B>
  <DD><CODE><A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/NullPointerException.html" title="class or interface in java.lang">NullPointerException</A></CODE> - if the chars parameter is null.</DL>
  </DD>
  </DL>
  <HR>
  
  <A NAME="writeString(char[])"><!-- --></A><H3>
  writeString</H3>
  <PRE>
  public final <A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html" title="class in com.sleepycat.bind.tuple">TupleOutput</A> <B>writeString</B>(char[]&nbsp;chars)</PRE>
  <DL>
  <DD>Writes the specified characters to the buffer, converting each character
   to UTF format.
   Note that zero (0x0000) character values are encoded as non-zero values.
   Writes values that can be read using <A HREF="../../../../com/sleepycat/bind/tuple/TupleInput.html#readString(int)"><CODE>TupleInput.readString(int)</CODE></A>
   or <A HREF="../../../../com/sleepycat/bind/tuple/TupleInput.html#readString(char[])"><CODE>TupleInput.readString(char[])</CODE></A>.
  <P>
  <DD><DL>
  <DT><B>Parameters:</B><DD><CODE>chars</CODE> - is the array of characters to be written.
  <DT><B>Returns:</B><DD>this tuple output object.
  <DT><B>Throws:</B>
  <DD><CODE><A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/NullPointerException.html" title="class or interface in java.lang">NullPointerException</A></CODE> - if the chars parameter is null.</DL>
  </DD>
  </DL>
  <HR>
  
  <A NAME="writeUnsignedByte(int)"><!-- --></A><H3>
  writeUnsignedByte</H3>
  <PRE>
  public final <A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html" title="class in com.sleepycat.bind.tuple">TupleOutput</A> <B>writeUnsignedByte</B>(int&nbsp;val)</PRE>
  <DL>
  <DD>Writes an unsigned byte (one byte) value to the buffer.
   Writes values that can be read using <A HREF="../../../../com/sleepycat/bind/tuple/TupleInput.html#readUnsignedByte()"><CODE>TupleInput.readUnsignedByte()</CODE></A>.
  <P>
  <DD><DL>
  <DT><B>Parameters:</B><DD><CODE>val</CODE> - is the value to write to the buffer.
  <DT><B>Returns:</B><DD>this tuple output object.</DL>
  </DD>
  </DL>
  <HR>
  
  <A NAME="writeUnsignedShort(int)"><!-- --></A><H3>
  writeUnsignedShort</H3>
  <PRE>
  public final <A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html" title="class in com.sleepycat.bind.tuple">TupleOutput</A> <B>writeUnsignedShort</B>(int&nbsp;val)</PRE>
  <DL>
  <DD>Writes an unsigned short (two byte) value to the buffer.
   Writes values that can be read using <A HREF="../../../../com/sleepycat/bind/tuple/TupleInput.html#readUnsignedShort()"><CODE>TupleInput.readUnsignedShort()</CODE></A>.
  <P>
  <DD><DL>
  <DT><B>Parameters:</B><DD><CODE>val</CODE> - is the value to write to the buffer.
  <DT><B>Returns:</B><DD>this tuple output object.</DL>
  </DD>
  </DL>
  <HR>
  
  <A NAME="writeUnsignedInt(long)"><!-- --></A><H3>
  writeUnsignedInt</H3>
  <PRE>
  public final <A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html" title="class in com.sleepycat.bind.tuple">TupleOutput</A> <B>writeUnsignedInt</B>(long&nbsp;val)</PRE>
  <DL>
  <DD>Writes an unsigned int (four byte) value to the buffer.
   Writes values that can be read using <A HREF="../../../../com/sleepycat/bind/tuple/TupleInput.html#readUnsignedInt()"><CODE>TupleInput.readUnsignedInt()</CODE></A>.
  <P>
  <DD><DL>
  <DT><B>Parameters:</B><DD><CODE>val</CODE> - is the value to write to the buffer.
  <DT><B>Returns:</B><DD>this tuple output object.</DL>
  </DD>
  </DL>
  <HR>
  
  <A NAME="writePackedInt(int)"><!-- --></A><H3>
  writePackedInt</H3>
  <PRE>
  public final void <B>writePackedInt</B>(int&nbsp;val)</PRE>
  <DL>
  <DD>Writes a packed integer.  Note that packed integers are not appropriate
   for sorted values (keys) unless a custom comparator is used.
  <P>
  <DD><DL>
  <DT><B>See Also:</B><DD><A HREF="../../../../com/sleepycat/util/PackedInteger.html" title="class in com.sleepycat.util"><CODE>PackedInteger</CODE></A></DL>
  </DD>
  </DL>
  <HR>
  
  <A NAME="writePackedLong(long)"><!-- --></A><H3>
  writePackedLong</H3>
  <PRE>
  public final void <B>writePackedLong</B>(long&nbsp;val)</PRE>
  <DL>
  <DD>Writes a packed long integer.  Note that packed integers are not
   appropriate for sorted values (keys) unless a custom comparator is used.
  <P>
  <DD><DL>
  <DT><B>See Also:</B><DD><A HREF="../../../../com/sleepycat/util/PackedInteger.html" title="class in com.sleepycat.util"><CODE>PackedInteger</CODE></A></DL>
  </DD>
  </DL>
  <HR>
  
  <A NAME="writeBigInteger(java.math.BigInteger)"><!-- --></A><H3>
  writeBigInteger</H3>
  <PRE>
  public final <A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html" title="class in com.sleepycat.bind.tuple">TupleOutput</A> <B>writeBigInteger</B>(<A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/math/BigInteger.html" title="class or interface in java.math">BigInteger</A>&nbsp;val)</PRE>
  <DL>
  <DD>Writes a <code>BigInteger</code>.  Supported <code>BigInteger</code> values are
   limited to those with a byte array (<A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/math/BigInteger.html#toByteArray()" title="class or interface in java.math"><CODE>BigInteger.toByteArray()</CODE></A>)
   representation with a size of 0x7fff bytes or less.  The maximum <code>BigInteger</code> value is (2<sup>0x3fff7</sup> - 1) and the minimum value is
   (-2<sup>0x3fff7</sup>).
  
   <p>The byte format for a <code>BigInteger</code> value is:</p>
   <ul>
   <li>Byte 0 and 1: The length of the following bytes, negated if the
   <code>BigInteger</code> value is negative, and written as a sorted value as
   if <A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html#writeShort(int)"><CODE>writeShort(int)</CODE></A> were called.</li>
   <li>Byte 2: The first byte of the <A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/math/BigInteger.html#toByteArray()" title="class or interface in java.math"><CODE>BigInteger.toByteArray()</CODE></A> array,
   written as a sorted value as if <A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html#writeByte(int)"><CODE>writeByte(int)</CODE></A> were called.</li>
   <li>Byte 3 to N: The second and remaining bytes, if any, of the <A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/math/BigInteger.html#toByteArray()" title="class or interface in java.math"><CODE>BigInteger.toByteArray()</CODE></A> array, written without modification.</li>
   </ul>
   <p>This format provides correct default sorting when the default
   byte-by-byte comparison is used.</p>
  <P>
  <DD><DL>
  
  <DT><B>Throws:</B>
  <DD><CODE><A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/NullPointerException.html" title="class or interface in java.lang">NullPointerException</A></CODE> - if val is null.
  <DD><CODE><A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/lang/IllegalArgumentException.html" title="class or interface in java.lang">IllegalArgumentException</A></CODE> - if the byte array representation of val
   is larger than 0x7fff bytes.</DL>
  </DD>
  </DL>
  <HR>
  
  <A NAME="getBigIntegerByteLength(java.math.BigInteger)"><!-- --></A><H3>
  getBigIntegerByteLength</H3>
  <PRE>
  public static int <B>getBigIntegerByteLength</B>(<A HREF="http://java.sun.com/j2se/1.5.0/docs/api/java/math/BigInteger.html" title="class or interface in java.math">BigInteger</A>&nbsp;val)</PRE>
  <DL>
  <DD>Returns the byte length of a given <code>BigInteger</code> value.
  <P>
  <DD><DL>
  <DT><B>See Also:</B><DD><A HREF="../../../../com/sleepycat/bind/tuple/TupleOutput.html#writeBigInteger(java.math.BigInteger)"><CODE>writeBigInteger(java.math.BigInteger)</CODE></A></DL>
  </DD>
  </DL>
  <!-- ========= END OF CLASS DATA ========= -->
  <HR>
  
  
  <!-- ======= START OF BOTTOM NAVBAR ====== -->
  <A NAME="navbar_bottom"><!-- --></A>
  <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
  <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
  <TR>
  <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
  <A NAME="navbar_bottom_firstrow"><!-- --></A>
  <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
    <TR ALIGN="center" VALIGN="top">
    <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
    <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
    <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
    <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="class-use/TupleOutput.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
    <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
    <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
    <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
    <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
    </TR>
  </TABLE>
  </TD>
  <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
  <b>Berkeley DB</b><br><font size="-1"> version 4.7.25</font></EM>
  </TD>
  </TR>
  
  <TR>
  <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
  &nbsp;<A HREF="../../../../com/sleepycat/bind/tuple/TupleMarshalledBinding.html" title="class in com.sleepycat.bind.tuple"><B>PREV CLASS</B></A>&nbsp;
  &nbsp;<A HREF="../../../../com/sleepycat/bind/tuple/TupleTupleBinding.html" title="class in com.sleepycat.bind.tuple"><B>NEXT CLASS</B></A></FONT></TD>
  <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
    <A HREF="../../../../index.html?com/sleepycat/bind/tuple/TupleOutput.html" target="_top"><B>FRAMES</B></A>  &nbsp;
  &nbsp;<A HREF="TupleOutput.html" target="_top"><B>NO FRAMES</B></A>  &nbsp;
  &nbsp;<SCRIPT type="text/javascript">
    <!--
    if(window==top) {
      document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
    }
    //-->
  </SCRIPT>
  <NOSCRIPT>
    <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
  </NOSCRIPT>
  
  
  </FONT></TD>
  </TR>
  <TR>
  <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
    SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;<A HREF="#fields_inherited_from_class_com.sleepycat.util.FastOutputStream">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
  <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
  DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
  </TR>
  </TABLE>
  <A NAME="skip-navbar_bottom"></A>
  <!-- ======== END OF BOTTOM NAVBAR ======= -->
  
  <HR>
  <font size=1>Copyright (c) 1996,2008 Oracle.  All rights reserved.</font>
  </BODY>
  </HTML>
  