using System.Collections.Generic; using Lucene.Net.Search; namespace VideoGameQuotes.Api.Search.Lucene { public static class LuceneExtensions { public static IEnumerable ToEnumerable(this Hits hits) { var iterator = hits.Iterator(); while (iterator.MoveNext()) { yield return (Hit)iterator.Current; } } } }