Example #1
0
 public void GetMostRecentBuildInBuildConfig(BuildConfig buildConfig, Action<BuildViewModel> callback)
 {
     if (callback == null) throw new ArgumentNullException("callback");
     worker.QueueWork(delegate
         {
             BuildLocator locator = BuildLocator.WithDimensions(
                 BuildTypeLocator.WithId(buildConfig.Id), maxResults: 1);
             callback(client.BuildsByBuildLocator(locator).Select(
                 x => new BuildViewModel(x, this)).FirstOrDefault());
         });
 }
Example #2
0
 public void GetBuildsInBuildConfig(BuildConfig buildConfig, Action<IEnumerable<BuildViewModel>> callback)
 {
     if (callback == null) throw new ArgumentNullException("callback");
     worker.QueueWork(delegate
         {
             BuildLocator locator = BuildLocator.WithDimensions(
                 BuildTypeLocator.WithId(buildConfig.Id));
             callback(client.BuildsByBuildLocator(locator).Select(
                 x => new BuildViewModel(x, this)));
         });
 }