public void StartSearch() { waitTask = Task.Factory.StartNew(async() => { searchTask = bkRoot.SearchSubTree(searchTerm, searchThreshold, cts.Token); try { result = await searchTask; } catch (OperationCanceledException oce) { } }); }
public void StartSearch(T searchTerm, int threshold) { InitSearch(); searchTask = bkRoot.SearchSubTree(searchTerm, threshold, cts.Token); }