public void FetchInitialDRs() { foreach (string lang in DRLanguages) { DRFetcher drFetcher = new DRFetcher(this, lang, OnReceivedDRs); drFetcher.BeginFetching(); } }
public void FetchDROfDate(string lang, string fetchDate, Action <DailyReflection> callback) { DailyReflection dr = GetDROfDate(lang, fetchDate); if (dr != null) { if (callback != null) { callback(dr); } } else { DRFetcher drFetcher = new DRFetcher(this, lang, OnReceivedDROfDate); drFetcher.InitContext((object)callback); drFetcher.FetchFromServer(fetchDate); } }