Exemplo n.º 1
0
        private DocumentScore[] Collect(QueryContext query)
        {
            var scores = new List <DocumentScore[]>();

            foreach (var version in _versions)
            {
                using (var readSession = _sessionFactory.OpenReadSession(version.VersionId))
                {
                    scores.Add(Collect(query, readSession));
                }
            }
            return(scores.CombineTakingLatestVersion());
        }
Exemplo n.º 2
0
        private IList <IList <DocumentScore> > Collect(IList <QueryContext> query)
        {
            var scores = new List <IList <DocumentScore> >(_versions.Count);

            for (var index = 0; index < _versions.Count; index++)
            {
                using (var readSession = (IFullTextReadSession)_sessionFactory.OpenReadSession(_versions[index]))
                {
                    scores.Add(Collect(query, readSession));
                }
            }

            return(scores);
        }