[ 
https://issues.apache.org/jira/browse/LUCENE-8306?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16497764#comment-16497764
 ] 

Jim Ferenczi commented on LUCENE-8306:
--------------------------------------

We discussed with [~romseygeek] about the current status and came to the 
conclusion that it would be simpler to just add a method inside the 
MatchesIterator to return the inner matches. It could be another 
MatchesIterator that explodes the parent matches into the nested matches 
contained in the current interval. This would simplify the API and we would not 
need to introduce another collector.

We also discuss the fact that we don't need to get the individual terms, just 
getting the inner matches should be fine. However we need a way to distinguish 
matches coming from different queries so instead of returning the individual 
terms we could add a label that identifies each matches and link it to the 
original query. It can be a simple ID, the goal is just to be able to regroup 
matches generated by the same query. 

> Allow iteration over the term positions of a Match
> --------------------------------------------------
>
>                 Key: LUCENE-8306
>                 URL: https://issues.apache.org/jira/browse/LUCENE-8306
>             Project: Lucene - Core
>          Issue Type: New Feature
>            Reporter: Alan Woodward
>            Assignee: Alan Woodward
>            Priority: Major
>         Attachments: LUCENE-8306.patch, LUCENE-8306.patch
>
>
> For multi-term queries such as phrase queries, the matches API currently just 
> returns information about the span of the whole match.  It would be useful to 
> also expose information about the matching terms within the phrase.  The same 
> would apply to Spans and Interval queries.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org
For additional commands, e-mail: dev-h...@lucene.apache.org

Reply via email to