Exemple #1
0
        /// <summary>
        /// Retrieves the <c>CLOB</c> value designated by this <c>IClob</c> object as
        /// an ASCII stream.
        /// </summary>
        /// <returns>
        /// A <see cref="System.IO.Stream"/> containing the <c>CLOB</c> data.
        /// </returns>
        /// <remarks>
        /// Note that multi-byte characters contained in the <c>CLOB</c> data
        /// are UTF-8 encoded in the stream.
        /// </remarks>
        /// <exception cref="System.Data.Common.DbException">
        /// If there is an error accessing the <c>CLOB</c> value.
        /// </exception>
        Stream IClob.GetAsciiStream()
        {
            lock (this)
            {
                CheckFree();

                try
                {
                    return(new JavaInputStreamWrapper(m_clob.getAsciiStream()));
                }
                catch (java.sql.SQLException se)
                {
                    throw new HsqlDataSourceException(se);
                }
                catch (java.lang.Exception e)
                {
                    throw new HsqlDataSourceException(e.toString(), e);
                }
            }
        }