Class SQLOutputImpl

  • All Implemented Interfaces:
    SQLOutput

    public class SQLOutputImpl
    extends Object
    implements SQLOutput
    The output stream for writing the attributes of a custom-mapped user-defined type (UDT) back to the database. The driver uses this interface internally, and its methods are never directly invoked by an application programmer.

    When an application calls the method PreparedStatement.setObject, the driver checks to see whether the value to be written is a UDT with a custom mapping. If it is, there will be an entry in a type map containing the Class object for the class that implements SQLData for this UDT. If the value to be written is an instance of SQLData, the driver will create an instance of SQLOutputImpl and pass it to the method SQLData.writeSQL. The method writeSQL in turn calls the appropriate SQLOutputImpl.writeXXX methods to write data from the SQLData object to the SQLOutputImpl output stream as the representation of an SQL user-defined type.

    Since:
    1.5
    • Constructor Summary

      Constructors 
      Constructor Description
      SQLOutputImpl​(Vector<?> attributes, Map<String,​?> map)
      Creates a new SQLOutputImpl object initialized with the given vector of attributes and type map.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void writeArray​(Array x)
      Writes an Array object in the Java programming language to this SQLOutputImpl object.
      void writeAsciiStream​(InputStream x)
      Writes a stream of ASCII characters to this SQLOutputImpl object.
      void writeBigDecimal​(BigDecimal x)
      Writes a java.math.BigDecimal object in the Java programming language to this SQLOutputImpl object.
      void writeBinaryStream​(InputStream x)
      Writes a stream of uninterpreted bytes to this SQLOutputImpl object.
      void writeBlob​(Blob x)
      Writes a Blob object in the Java programming language to this SQLOutputImpl object.
      void writeBoolean​(boolean x)
      Writes a boolean in the Java programming language to this SQLOutputImpl object.
      void writeByte​(byte x)
      Writes a byte in the Java programming language to this SQLOutputImpl object.
      void writeBytes​(byte[] x)
      Writes an array of bytes in the Java programming language to this SQLOutputImpl object.
      void writeCharacterStream​(Reader x)
      Writes a stream of Unicode characters to this SQLOutputImpl object.
      void