示例#1
0
 private void ObserverInitialize()
 {
     reactiveObserver = new ReactiveObserver <IEnumerable <PostSummary> >(async() => await GetData(),
                                                                          (data) =>
     {
         if (PostSummaries.Count != data.Count())
         {
             PostSummaries = new ObservableCollection <PostSummary>(data);
         }
     });
 }
示例#2
0
 private void ObserverInitialize()
 {
     reactiveObserver = new ReactiveObserver <IEnumerable <Comment> >(async() => await LoadCommentsAsync(),
                                                                      (data) =>
     {
         if (Comments.Count != data.Count())
         {
             Comments = new ObservableCollection <Comment>(data);
         }
     });
 }