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

Alan Woodward commented on LUCENE-6371:
---------------------------------------

It's the same logic as https://issues.apache.org/jira/browse/LUCENE-6425 
really.  Spans should only be pulled from a SpanQuery after it has been 
rewritten against a searcher, so it makes sense that they should be on 
SpanWeight rather than SpanQuery.  And it simplifies pulling Spans for use in 
things like highlighting (or payload collection, as here) - before you had to 
rewrite, extract terms, build the termcontexts map and then call getSpans(); 
now you just call IndexSearcher.getNormalizedWeight(), cast to a SpanWeight and 
call getSpans.

> Improve Spans payload collection
> --------------------------------
>
>                 Key: LUCENE-6371
>                 URL: https://issues.apache.org/jira/browse/LUCENE-6371
>             Project: Lucene - Core
>          Issue Type: Improvement
>            Reporter: Paul Elschot
>            Assignee: Alan Woodward
>            Priority: Minor
>             Fix For: Trunk, 5.3
>
>         Attachments: LUCENE-6371.patch, LUCENE-6371.patch, LUCENE-6371.patch, 
> LUCENE-6371.patch
>
>
> Spin off from LUCENE-6308, see the comments there from around 23 March 2015.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

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

Reply via email to