private void Add(ExtractedResult result, HashSet <string> otherRunLocations, int index) { // Find the LocationSpecifier for the Result (the first Uri or FQN also in the other Run) string locationSpecifier = WhereComparer.LocationSpecifier(result, otherRunLocations); // Add Result attributes used as matching hints in a "bucket" for the Rule x LocationSpecifier x AttributeName foreach (WhatComponent component in result.WhatProperties(locationSpecifier)) { Add(component, index); } }
private static void BuildMap(List <ExtractedResult> results, WhatMap whatMap, TrustMap trustMap, HashSet <string> otherRunLocations) { // Populate the WhatMap and TrustMap for (int i = 0; i < results.Count; ++i) { ExtractedResult result = results[i]; // Find the LocationSpecifier for the Result (the first Uri or FQN also in the other Run) string locationSpecifier = WhereComparer.LocationSpecifier(result, otherRunLocations); foreach (WhatComponent component in WhatComparer.WhatProperties(result, locationSpecifier)) { // Add Result attributes used as matching hints in a "bucket" for the Rule x LocationSpecifier x AttributeName whatMap.Add(component, i); // Track attribute usage to determine per-attribute trust trustMap.Add(component); } } }