亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關(guān)于我們
? 蟲蟲下載站

?? sqlitedatareader.cs

?? sqlite 3.3.8 支持加密的版本
?? CS
?? 第 1 頁 / 共 3 頁
字號:
?/********************************************************
 * ADO.NET 2.0 Data Provider for SQLite Version 3.X
 * Written by Robert Simpson (robert@blackcastlesoft.com)
 * 
 * Released to the public domain, use at your own risk!
 ********************************************************/

namespace System.Data.SQLite
{
  using System;
  using System.Data;
  using System.Data.Common;
  using System.Collections.Generic;
  using System.Globalization;
  using System.Reflection;

  /// <summary>
  /// SQLite implementation of DbDataReader.
  /// </summary>
  public sealed class SQLiteDataReader : DbDataReader
  {
    /// <summary>
    /// Underlying command this reader is attached to
    /// </summary>
    private SQLiteCommand   _command;
    /// <summary>
    /// Index of the current statement in the command being processed
    /// </summary>
    private int             _activeStatementIndex;
    /// <summary>
    /// Current statement being Read()
    /// </summary>
    private SQLiteStatement _activeStatement;
    /// <summary>
    /// State of the current statement being processed.
    /// -1 = First Step() executed, so the first Read() will be ignored
    ///  0 = Actively reading
    ///  1 = Finished reading
    ///  2 = Non-row-returning statement, no records
    /// </summary>
    private int             _readingState;
    /// <summary>
    /// Number of records affected by the insert/update statements executed on the command
    /// </summary>
    private int             _rowsAffected;
    /// <summary>
    /// Count of fields (columns) in the row-returning statement currently being processed
    /// </summary>
    private int             _fieldCount;
    /// <summary>
    /// Datatypes of active fields (columns) in the current statement, used for type-restricting data
    /// </summary>
    private SQLiteType[]    _fieldTypeArray;

    /// <summary>
    /// The behavior of the datareader
    /// </summary>
    private CommandBehavior _commandBehavior;

    /// <summary>
    /// If set, then dispose of the command object when the reader is finished
    /// </summary>
    internal bool           _disposeCommand;

    /// <summary>
    /// Internal constructor, initializes the datareader and sets up to begin executing statements
    /// </summary>
    /// <param name="cmd">The SQLiteCommand this data reader is for</param>
    /// <param name="behave">The expected behavior of the data reader</param>
    internal SQLiteDataReader(SQLiteCommand cmd, CommandBehavior behave)
    {
      _command = cmd;
      _commandBehavior = behave;
      _activeStatementIndex = -1;
      _activeStatement = null;
      _rowsAffected = -1;
      _fieldCount = -1;

      if (_command != null)
        NextResult();
    }

    /// <summary>
    /// Closes the datareader, potentially closing the connection as well if CommandBehavior.CloseConnection was specified.
    /// </summary>
    public override void Close()
    {
      if (_command != null)
      {
        while (NextResult())
        {
        }
        _command.ClearDataReader();

        if (_disposeCommand)
          ((IDisposable)_command).Dispose();
      }

      // If the datareader's behavior includes closing the connection, then do so here.
      if ((_commandBehavior & CommandBehavior.CloseConnection) != 0)
        _command.Connection.Close();

      _command = null;
      _activeStatement = null;
      _fieldTypeArray = null;
    }

    /// <summary>
    /// Disposes the datareader.  Calls Close() to ensure everything is cleaned up.
    /// </summary>
    protected override void Dispose(bool disposing)
    {
      base.Dispose(disposing);
      GC.SuppressFinalize(this);
    }

    /// <summary>
    /// Throw an error if the datareader is closed
    /// </summary>
    private void CheckClosed()
    {
      if (_command == null)
        throw new InvalidOperationException("DataReader has been closed");
    }

    /// <summary>
    /// Throw an error if a row is not loaded
    /// </summary>
    private void CheckValidRow()
    {
      if (_readingState != 0)
        throw new InvalidOperationException("No current row");
    }

    /// <summary>
    /// Enumerator support
    /// </summary>
    /// <returns>Returns a DbEnumerator object.</returns>
    public override Collections.IEnumerator GetEnumerator()
    {
      return new DbEnumerator(this);
    }

    /// <summary>
    /// Not implemented.  Returns 0
    /// </summary>
    public override int Depth
    {
      get
      {
        CheckClosed();
        return 0;
      }
    }

    /// <summary>
    /// Returns the number of columns in the current resultset
    /// </summary>
    public override int FieldCount
    {
      get
      {
        CheckClosed();
        return _fieldCount;
      }
    }

    /// <summary>
    /// SQLite is inherently un-typed.  All datatypes in SQLite are natively strings.  The definition of the columns of a table
    /// and the affinity of returned types are all we have to go on to type-restrict data in the reader.
    /// 
    /// This function attempts to verify that the type of data being requested of a column matches the datatype of the column.  In
    /// the case of columns that are not backed into a table definition, we attempt to match up the affinity of a column (int, double, string or blob)
    /// to a set of known types that closely match that affinity.  It's not an exact science, but its the best we can do.
    /// </summary>
    /// <returns>
    /// This function throws an InvalidTypeCast() exception if the requested type doesn't match the column's definition or affinity.
    /// </returns>
    /// <param name="i">The index of the column to type-check</param>
    /// <param name="typ">The type we want to get out of the column</param>
    private TypeAffinity VerifyType(int i, DbType typ)
    {
      CheckClosed();
      CheckValidRow();
      TypeAffinity affinity = _activeStatement._sql.ColumnAffinity(_activeStatement, i);

      switch (affinity)
      {
        case TypeAffinity.Int64:
          if (typ == DbType.Int16) return affinity;
          if (typ == DbType.Int32) return affinity;
          if (typ == DbType.Int64) return affinity;
          if (typ == DbType.Boolean) return affinity;
          if (typ == DbType.Byte) return affinity;
          if (typ == DbType.DateTime && _command.Connection._sql._datetimeFormat == SQLiteDateFormats.Ticks) return affinity;
          break;
        case TypeAffinity.Double:
          if (typ == DbType.Single) return affinity;
          if (typ == DbType.Double) return affinity;
          if (typ == DbType.Decimal) return affinity;
          break;
        case TypeAffinity.Text:
          if (typ == DbType.SByte) return affinity;
          if (typ == DbType.String) return affinity;
          if (typ == DbType.SByte) return affinity;
          if (typ == DbType.Guid) return affinity;
          if (typ == DbType.DateTime) return affinity;
          break;
        case TypeAffinity.Blob:
          if (typ == DbType.Guid) return affinity;
          if (typ == DbType.String) return affinity;
          if (typ == DbType.Binary) return affinity;
          break;
      }

      throw new InvalidCastException();
    }

    /// <summary>
    /// Retrieves the column as a boolean value
    /// </summary>
    /// <param name="i">The index of the column to retrieve</param>
    /// <returns>bool</returns>
    public override bool GetBoolean(int i)
    {
      VerifyType(i, DbType.Boolean);
      return Convert.ToBoolean(GetValue(i), CultureInfo.CurrentCulture);
    }

    /// <summary>
    /// Retrieves the column as a single byte value
    /// </summary>
    /// <param name="i">The index of the column to retrieve</param>
    /// <returns>byte</returns>
    public override byte GetByte(int i)
    {
      VerifyType(i, DbType.Byte);
      return Convert.ToByte(_activeStatement._sql.GetInt32(_activeStatement, i));
    }

    /// <summary>
    /// Retrieves a column as an array of bytes (blob)
    /// </summary>
    /// <param name="i">The index of the column to retrieve</param>
    /// <param name="fieldOffset">The zero-based index of where to begin reading the data</param>
    /// <param name="buffer">The buffer to write the bytes into</param>
    /// <param name="bufferoffset">The zero-based index of where to begin writing into the array</param>
    /// <param name="length">The number of bytes to retrieve</param>
    /// <returns>The actual number of bytes written into the array</returns>
    /// <remarks>
    /// To determine the number of bytes in the column, pass a null value for the buffer.  The total length will be returned.
    /// </remarks>
    public override long GetBytes(int i, long fieldOffset, byte[] buffer, int bufferoffset, int length)
    {
      VerifyType(i, DbType.Binary);
      return _activeStatement._sql.GetBytes(_activeStatement, i, (int)fieldOffset, buffer, bufferoffset, length);
    }

    /// <summary>
    /// Returns the column as a single character
    /// </summary>
    /// <param name="i">The index of the column to retrieve</param>
    /// <returns>char</returns>
    public override char GetChar(int i)
    {
      VerifyType(i, DbType.SByte);
      return Convert.ToChar(_activeStatement._sql.GetInt32(_activeStatement, i));
    }

    /// <summary>
    /// Retrieves a column as an array of chars (blob)
    /// </summary>
    /// <param name="i">The index of the column to retrieve</param>
    /// <param name="fieldoffset">The zero-based index of where to begin reading the data</param>
    /// <param name="buffer">The buffer to write the characters into</param>
    /// <param name="bufferoffset">The zero-based index of where to begin writing into the array</param>
    /// <param name="length">The number of bytes to retrieve</param>
    /// <returns>The actual number of characters written into the array</returns>
    /// <remarks>
    /// To determine the number of characters in the column, pass a null value for the buffer.  The total length will be returned.
    /// </remarks>
    public override long GetChars(int i, long fieldoffset, char[] buffer, int bufferoffset, int length)
    {
      VerifyType(i, DbType.String);
      return _activeStatement._sql.GetChars(_activeStatement, i, (int)fieldoffset, buffer, bufferoffset, length);
    }

    /// <summary>
    /// Retrieves the name of the back-end datatype of the column
    /// </summary>

?? 快捷鍵說明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
2021国产精品久久精品| 日韩和的一区二区| 亚洲动漫第一页| 2019国产精品| 欧美久久久久久久久| 91福利在线播放| 一本色道a无线码一区v| 99麻豆久久久国产精品免费优播| 成人一道本在线| 97精品超碰一区二区三区| 波多野结衣一区二区三区| 成人久久久精品乱码一区二区三区| 国产成人午夜视频| 成+人+亚洲+综合天堂| www.综合网.com| 97se亚洲国产综合自在线观| 色综合色综合色综合色综合色综合| 国产麻豆精品在线观看| 成人性视频免费网站| av亚洲精华国产精华精华| 91色九色蝌蚪| 欧美色视频一区| 91麻豆精品国产自产在线| 日韩一区二区在线播放| 精品99一区二区| 国产日产欧美一区二区三区| 中文字幕一区二区三区精华液| 亚洲欧美偷拍另类a∨色屁股| 亚洲精品乱码久久久久久日本蜜臀| 亚洲中国最大av网站| 日韩黄色小视频| 国产一区二区剧情av在线| 9i在线看片成人免费| 色哟哟欧美精品| 欧美一区二区免费视频| 久久久噜噜噜久久中文字幕色伊伊| 国产精品美女视频| 香蕉成人伊视频在线观看| 国产一区二区三区四| 91色综合久久久久婷婷| 欧美一区二区精品久久911| 国产偷国产偷精品高清尤物| 一区二区三区四区在线| 免费成人你懂的| 99久久久久久| 日韩视频在线你懂得| 亚洲国产精品成人综合 | 1区2区3区精品视频| 亚洲电影在线播放| 国产精品一区二区三区乱码| 色美美综合视频| 欧美大肚乱孕交hd孕妇| 最新国产成人在线观看| 蜜臀精品久久久久久蜜臀| 成人免费看视频| 欧美一区二区精品在线| 中文字幕一区二区5566日韩| 男男成人高潮片免费网站| 不卡av在线免费观看| 日韩欧美美女一区二区三区| 亚洲视频一区二区在线| 久久精品噜噜噜成人88aⅴ| 91同城在线观看| 久久婷婷一区二区三区| 亚洲第一狼人社区| 福利一区二区在线| 欧美mv和日韩mv国产网站| 一区二区三区精品在线| 国产91在线观看丝袜| 欧美成人vr18sexvr| 亚洲成在线观看| 91同城在线观看| 国产欧美日韩中文久久| 久久国产人妖系列| 欧美精品自拍偷拍| 一区二区三区精品| yourporn久久国产精品| 国产视频一区在线播放| 久久精品国产77777蜜臀| 欧美日韩一区二区三区四区| 亚洲人成在线观看一区二区| 成人午夜免费电影| 久久综合国产精品| 开心九九激情九九欧美日韩精美视频电影| 色偷偷一区二区三区| 国产精品成人网| 国产成人免费视频| 久久综合九色综合97婷婷女人| 日本在线不卡一区| 欧美日韩不卡一区二区| 亚洲午夜在线电影| 在线精品视频免费播放| 亚洲色欲色欲www| 99视频在线观看一区三区| 国产女主播一区| 国产精品亚洲一区二区三区在线| 精品免费视频.| 国内精品视频666| 精品美女一区二区| 精品一区二区综合| 精品少妇一区二区三区| 国产一区二区美女诱惑| 久久五月婷婷丁香社区| 国产精品一区三区| 国产女主播在线一区二区| 成人美女在线观看| 中文字幕亚洲区| 91小视频免费看| 亚洲精品va在线观看| 在线欧美日韩精品| 亚洲成人综合网站| 8x8x8国产精品| 久久精品国产99国产| 国产日韩av一区| 91视频免费观看| 亚洲福利视频三区| 欧美久久久久久久久| 蜜臀精品一区二区三区在线观看| 欧美大片拔萝卜| 成人午夜私人影院| 亚洲欧美日韩精品久久久久| 欧美在线|欧美| 奇米色一区二区三区四区| 精品国产91亚洲一区二区三区婷婷| 国产一区二区三区免费| 国产精品乱人伦| 在线观看国产91| 日本欧美一区二区在线观看| 精品电影一区二区三区| 成人午夜精品一区二区三区| 亚洲美女精品一区| 欧美精品vⅰdeose4hd| 国产在线播放一区二区三区| 欧美国产日韩在线观看| 欧美性做爰猛烈叫床潮| 看片的网站亚洲| 中文字幕中文字幕中文字幕亚洲无线| 一本色道久久综合狠狠躁的推荐 | 国产在线视频一区二区| 国产精品久久久久一区| 在线观看日韩一区| 久久电影网站中文字幕| 欧美mv和日韩mv国产网站| 日韩欧美自拍偷拍| 国产一区高清在线| 亚洲三级小视频| 日韩视频免费观看高清完整版| 国产呦萝稀缺另类资源| 一区二区三区蜜桃| 欧美tickling挠脚心丨vk| 成人不卡免费av| 日本在线不卡视频| 中文字幕亚洲一区二区av在线| 91精品欧美福利在线观看| 成人高清视频免费观看| 午夜精品国产更新| 国产精品毛片a∨一区二区三区| 91精品婷婷国产综合久久性色| 不卡一卡二卡三乱码免费网站| 肉丝袜脚交视频一区二区| 国产精品久久看| 精品国产人成亚洲区| 在线视频国内自拍亚洲视频| 国产乱码精品一区二区三区忘忧草 | 欧美一区二区三区不卡| 97精品久久久午夜一区二区三区 | 美女mm1313爽爽久久久蜜臀| 美女视频黄 久久| 亚洲一区视频在线| 精品国产乱码久久久久久图片| 91色porny| 国产成人鲁色资源国产91色综 | 成人18精品视频| 精品一区二区免费视频| 亚洲高清免费在线| 国产精品久久久久久久久免费樱桃| 欧美一级高清片| 91极品美女在线| 成人午夜视频网站| 国产精品中文有码| 另类小说图片综合网| 一区二区三区不卡视频在线观看| 久久欧美中文字幕| 日韩免费视频一区二区| 欧美日韩国产天堂| 色先锋aa成人| 91麻豆国产精品久久| 成人精品国产一区二区4080| 国产一区二三区好的| 美日韩一区二区三区| 天天做天天摸天天爽国产一区 | 日本高清视频一区二区| 高清久久久久久| 国产美女精品人人做人人爽| 美女一区二区久久| 午夜天堂影视香蕉久久| 亚洲一区二区综合| 一区二区三区中文字幕电影| 亚洲欧洲一区二区在线播放| 在线成人午夜影院|