Microsoft.DocAsCode.Build.Engine.DocumentBuildContext.ResolveByXRefMaps C# (CSharp) Method

ResolveByXRefMaps() private method

private ResolveByXRefMaps ( List uidList, XRefSpec>.ConcurrentDictionary externalXRefSpec ) : List
uidList List
externalXRefSpec XRefSpec>.ConcurrentDictionary
return List
        private List<string> ResolveByXRefMaps(List<string> uidList, ConcurrentDictionary<string, XRefSpec> externalXRefSpec)
        {
            if (_reader == null)
            {
                return uidList;
            }
            var reader = _reader.Result;
            var list = new List<string>();
            foreach (var uid in uidList)
            {
                var spec = reader.Find(uid);
                if (spec != null)
                {
                    externalXRefSpec.AddOrUpdate(uid, spec, (_, old) => old + spec);
                }
                else
                {
                    list.Add(uid);
                }
            }
            Logger.LogInfo($"{uidList.Count - list.Count} external references found in {XRefMapUrls.Length} xref maps.");
            return list;
        }