romseygeek commented on a change in pull request #1045: LUCENE-9072: Find matching terms from Matches API URL: https://github.com/apache/lucene-solr/pull/1045#discussion_r363673942
########## File path: lucene/core/src/java/org/apache/lucene/search/Matches.java ########## @@ -44,4 +47,9 @@ */ Collection<Matches> getSubMatches(); + /** + * Find all matching terms + */ + void getMatchingTerms(Consumer<Term> termsConsumer) throws IOException; + Review comment: Can you not already do this with the plain `MatchesIterator`? It will give you the start offset and end offset of matching sloppy phrases, and you can use those to pull phrases from the source. ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org With regards, Apache Git Services --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@lucene.apache.org For additional commands, e-mail: issues-h...@lucene.apache.org