lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Robert Muir <rcm...@gmail.com>
Subject Re: Depreciated IntField field in v6
Date Fri, 15 Apr 2016 16:40:51 GMT
On Fri, Apr 15, 2016 at 11:48 AM, Greg Huber <gregh3269@gmail.com> wrote:
> Hello,
>
> I was using the IntField field to set the weight on my suggester.
> (LegacyIntField works)
>
> old:
>
> document.add(new IntField(
>                     FieldConstants.LUCENE_WEIGHT_LINES,
> catalogue.getSearchWeight(), Field.Store.YES));
>
> I tried to use the IntPoint but it does not seem to work:
>
> new:
>
> document.add(new IntPoint(FieldConstants.LUCENE_WEIGHT_LINES,
>                     catalogue.getSearchWeight()));
>
> Is this the correct way t do it now?  There is no Field.Store.YES?

It is equivalent to Field.Store.NO: it just indexes it for search. If
you want to store separately you need to also add a StoredField (can
be the same field name of course).

I opened this issue to improve the docs:
https://issues.apache.org/jira/browse/LUCENE-7223

---------------------------------------------------------------------
To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
For additional commands, e-mail: java-user-help@lucene.apache.org


Mime
View raw message