internal UnqliteDB(UnqliteDBProxy proxy)
 {
     if (proxy == null)
     {
         throw new ArgumentNullException("dbproxy");
     }
     dbProxy = proxy;
 }
 internal KeyValueCursor(Interop.UnqliteDBProxy dbProxy, bool forwardCursor)
 {
     this.dbProxy = dbProxy;
     bool success = dbProxy.InitKVCursor(out cursor);
     if (success)
     {
         if (forwardCursor)
         {
             success = dbProxy.KVMoveToFirstEntry(cursor);
         }
         else
         {
             success = dbProxy.KVMoveToLastEntry(cursor);
         }
         Open = true;
     }
     else
     {
         Open = false;
     }
 }
Beispiel #3
0
        internal KeyValueCursor(Interop.UnqliteDBProxy dbProxy, bool forwardCursor)
        {
            this.dbProxy = dbProxy;
            bool success = dbProxy.InitKVCursor(out cursor);

            if (success)
            {
                if (forwardCursor)
                {
                    success = dbProxy.KVMoveToFirstEntry(cursor);
                }
                else
                {
                    success = dbProxy.KVMoveToLastEntry(cursor);
                }
                Open = true;
            }
            else
            {
                Open = false;
            }
        }
 public static UnqliteDB Create()
 {
     var proxy = new UnqliteDBProxy();
     return new UnqliteDB(proxy);
 }