Ejemplo n.º 1
0
 public static int[] GetSegmentPriorities(Calculator calc, int segment) => calc.GetPriorities(segment).Select(q => q.Key).ToArray();
Ejemplo n.º 2
0
 public static int[] GetActualPriorities(Calculator calc) => calc.GetPriorities().Select(q => q.Key).ToArray();
Ejemplo n.º 3
0
 public static IEnumerable<int> Calculate(Calculator calc, IEnumerable<int[]> perspectives)
 {
     foreach (var perspective in perspectives)
         yield return Calculate(calc, perspective);
 }
Ejemplo n.º 4
0
        /// <summary>
        /// Compares the provided perspective on priorities against the actual priorities
        /// </summary>
        public static int Calculate(Calculator calc, int[] perspectives)
        {
            var actuals = LimitToScale(GetActualPriorities(calc));

            return Calculate(actuals, perspectives);
        }
Ejemplo n.º 5
0
        /// <summary>
        /// Compares the segment's perspective on priorities against the actual priorities
        /// </summary>
        public static int Calculate(Calculator calc, int segment)
        {
            var perspectives = LimitToScale(GetSegmentPriorities(calc, segment));

            return Calculate(calc, perspectives);
        }