public async Task AddDocSearchResult(Doc_Search d) { UseCaseBase addDoc = new AddSearchResultUseCase(d); addDoc.SetCallBack(this); await addDoc.Execute(); }
public async Task AddDocSearch(Doc_Search d, IDoc_SearchCallback callback) { if (DBHandler.db == null) { DBHandler.DBConnection(); } try { int x = await DBHandler.db.InsertAsync(d); if (x > 0) { callback.Doc_SearchInsertSuccess(x); } else { callback.Doc_SearchInsertFail(); } } catch (Exception e) { System.Diagnostics.Debug.WriteLine("Doc_Search insert DAO fail"); } }
public AddSearchResultUseCase(Doc_Search d) { this.doc = d; }