AddResultProjects() public method

public AddResultProjects ( List matches ) : void
matches List
return void
Exemplo n.º 1
0
        private void FindProjects(Query query)
        {
            string searchTerm = query.GetSearchTermForProjectSearch();

            if (searchTerm == null)
            {
                return;
            }

            var search = new SortedSearch(i => projects[i], projects.Count);

            int low, high;

            search.FindBounds(searchTerm, out low, out high);
            if (high >= low)
            {
                var result = Enumerable
                             .Range(low, high - low + 1)
                             .Select(i => assemblies[projectToAssemblyIndexMap[projects[i]]])
                             .Take(MaxRawResults)
                             .ToList();
                query.AddResultProjects(result);
            }
        }
Exemplo n.º 2
0
        private void FindProjects(Query query)
        {
            string searchTerm = query.GetSearchTermForProjectSearch();
            if (searchTerm == null)
            {
                return;
            }

            var search = new SortedSearch(i => projects[i], projects.Count);

            int low, high;
            search.FindBounds(searchTerm, out low, out high);
            if (high >= low)
            {
                var result = Enumerable
                    .Range(low, high - low + 1)
                    .Select(i => assemblies[projectToAssemblyIndexMap[projects[i]]])
                    .Take(MaxRawResults)
                    .ToList();
                query.AddResultProjects(result);
            }
        }