コード例 #1
0
        public static Task <DatabaseObject> LoadSingleAsync(this BigDB bigDB, string table, string index, params object[] indexValue)
        {
            var tcs = new TaskCompletionSource <DatabaseObject>();

            bigDB.LoadSingle(table, index, indexValue, tcs.SetResult, tcs.SetException);
            return(tcs.Task);
        }
コード例 #2
0
 public static void GetInvitation(BigDB bigDb, InvitationType type, string sender, string recipient,
                                  Callback <Invitation> callback)
 {
     bigDb.LoadSingle(InvitationsTable, "BySenderAndRecipient",
                      new object[] { (int)type, sender, recipient }, dbo => { callback(new Invitation(dbo)); });
 }