[ 
https://issues.apache.org/jira/browse/LUCENE-7895?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Alan Woodward updated LUCENE-7895:
----------------------------------
    Attachment: LUCENE-7895.patch

Patch, adding two new protected methods to QueryBuilder:
* isMultiTerm(CharTermAttribute) is called for each analyzed term, with a 
default implementation that always returns false
* newSpanTermQuery(Term) is analogous to newTermQuery(Term)

If a query phrase has multiple tokens, one of which returns true from 
isMultiTerm, then QueryBuilder constructs a SpanQuery, rather than a 
PhraseQuery or MultiPhraseQuery.

> Add hooks to QueryBuilder to allow for the construction of MultiTermQueries 
> in phrases
> --------------------------------------------------------------------------------------
>
>                 Key: LUCENE-7895
>                 URL: https://issues.apache.org/jira/browse/LUCENE-7895
>             Project: Lucene - Core
>          Issue Type: New Feature
>            Reporter: Alan Woodward
>            Assignee: Alan Woodward
>         Attachments: LUCENE-7895.patch
>
>
> QueryBuilder currently allows subclasses to override simple term query 
> construction, which lets you support wildcard querying.  However, there is 
> currently no easy way to override phrase query construction to support 
> wildcards.



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to