public AsyncCheck FlushAsync() { AsyncCheck loading = new AsyncCheck(); WriteToJson(); var task = WriteToFileAsync(); task.ContinueWith(t => { loading.SetDone(); }); return(loading); }
public AsyncCheck ReloadAsync() { AsyncCheck loading = new AsyncCheck(); var task = ReadFromFileAsync(); task.ContinueWith(t => { Json = (JObject)t.Result; ReadFromJson(); loading.SetDone(); }); return(loading); }