예제 #1
0
 protected override void UpdateCacheForSuggestions(IPipeline pipeline)
 {
     _validDates.Clear();
     _validDates.AddRange(
         pipeline.CachedBuilds()
         .Where(b => b.QueueTime != null)
         .Select(b => (DateTime)b.QueueTime !)
         .Select(d => d.Date)
         .Distinct()
         .Take(MaxDatesToSuggest));
 }
예제 #2
0
 protected override void UpdateCacheForSuggestions(IPipeline pipeline)
 {
     _validDates.Clear();
     _validDates.AddRange(
         pipeline.CachedBuilds()
         .Where(b => b.QueueTime != null)
         .Select(b => (DateTime)b.QueueTime !)
         .Select(d => d.Date + TimeSpan.FromDays(1))     // this criteria checks for builds before the given date. Therefore a valid value for this build would be the day after
         .Distinct()
         .Take(MaxDatesToSuggest));
 }
예제 #3
0
 protected override IEnumerable <string> ResolveAllPossibleStringValues(IPipeline pipeline) => pipeline.CachedBuilds().Select(b => b.RequestedBy.DisplayName).Distinct();