protected override IPromise<object, Exception> LoadChildrenAsync()
 {
     var promise = Utility.ExecuteAsync(_web.IncludeLists().LoadAsync());
     promise.Done(() =>
     {
         var lists = _web.GetLists();
         Name = $"Lists ({lists.Length})";
         foreach (var list in lists.OrderBy(l => l.List.Title))
         {
             var l = list;
             Dispatcher.CurrentDispatcher.Invoke(DispatcherPriority.Background, new Action(() =>
             {
                 var viewModel = new SPListViewModel(l, this);
                 Children.Add(viewModel);
             }));
         }
     });
     return promise;
 }
 /// <summary>
 ///     Initializes a new instance of the SiteItemViewModel class.
 /// </summary>
 protected SPListContentTypeCollectionViewModel(SPListViewModel parent, bool lazyLoadChildren)
     : base(parent, lazyLoadChildren)
 {
 }
 public SPListContentTypeCollectionViewModel(SPClientList list, SPListViewModel parent)
     : this(parent, true)
 {
     if (list == null) throw new ArgumentNullException(nameof(list));
     _list = list;
 }
 /// <summary>
 ///     Initializes a new instance of the SiteItemViewModel class.
 /// </summary>
 protected SPFieldCollectionViewModel(SPListViewModel parent, bool lazyLoadChildren)
     : base(parent, lazyLoadChildren)
 {
 }