Example #1
0
 private void Dispose(bool disposing)
 {
     if (_disposed)
     {
         return;
     }
     Sqlite.Result r = Sqlite.Finalize(_statement);
     if (!disposing)
     {
         return;
     }
     GC.SuppressFinalize(this);
     _disposed = true;
     r.ThrowIfNotOK(nameof(Sqlite.Finalize));
 }
Example #2
0
 internal void BindNull(int index)
 {
     Sqlite.BindNull(_statement, index)
     .ThrowIfNotOK(nameof(Sqlite.BindNull));
 }
Example #3
0
 internal void BindFloat(int index, double value)
 {
     Sqlite.BindDouble(_statement, index, value)
     .ThrowIfNotOK(nameof(Sqlite.BindDouble));
 }
Example #4
0
 internal void BindInteger(int index, long value)
 {
     Sqlite.BindInt64(_statement, index, value)
     .ThrowIfNotOK(nameof(Sqlite.BindInt64));
 }
Example #5
0
 internal Statement(IntPtr statement)
 {
     _statement     = statement;
     ColumnCount    = Sqlite.ColumnCount(statement);
     ParameterCount = Sqlite.BindParameterCount(statement);
 }
Example #6
0
 public double AsFloat() => Sqlite.ColumnDouble(_statement, Index);
Example #7
0
 public long AsInteger() => Sqlite.ColumnInt64(_statement, Index);
Example #8
0
 public Column(IntPtr statement, int index)
 {
     _statement = statement;
     Index      = index;
     DataType   = Sqlite.ColumnType(statement, index);
 }