public static bool IsComplete(this IBenchmarkFile file, IEnumerable <string> algorithms, IEnumerable <Hardware> miningHardware) { var enumerable = miningHardware.ToList(); return(!enumerable.Except(file.HashRates.Select(i => i.Key)).Any() && enumerable.All(hardware => algorithms.All(algorithm => file.HashRates[hardware].ContainsKey(algorithm)))); }
public static bool IsComplete(this IBenchmarkFile file, IEnumerable <string> algorithms, Hardware miningHardware) { if (!file.HashRates.ContainsKey(miningHardware)) { return(false); } return(!algorithms.Except(file.HashRates[miningHardware].Keys).Any()); }
public static bool IsComplete(this IBenchmarkFile file, string algorithm, Hardware miningHardware) => file.HashRates.ContainsKey(miningHardware) && file.HashRates[miningHardware].ContainsKey(algorithm);
public static IEnumerable <(string algorithm, Hardware hardware)> GetUnfinishedAlgorithms( this IBenchmarkFile file, Miner miner, IEnumerable <Hardware> miningHardware) =>