/** * Returns the related attributes, the returned {@link AttributeSource} * is shared with the delegate {@code TermsEnum}. */ @Override public AttributeSource attributes() { return tenum.attributes(); }
@Override // make it synchronized here, to prevent double lazy init public synchronized AttributeSource attributes() { return super.attributes(); }
@Override public AttributeSource attributes() { return in.attributes(); }
@Override public void setNextEnum(TermsEnum termsEnum) { this.termsEnum = termsEnum; assert compareToLastTerm(null); // lazy init the initial ScoreTerm because comparator is not known on ctor: if (st == null) st = new ScoreTerm(new TermContext(topReaderContext)); boostAtt = termsEnum.attributes().addAttribute(BoostAttribute.class); }
private void buildField(XContentBuilder builder, final CharsRefBuilder spare, Fields theFields, Iterator<String> fieldIter) throws IOException { String fieldName = fieldIter.next(); builder.startObject(fieldName); Terms curTerms = theFields.terms(fieldName); // write field statistics buildFieldStatistics(builder, curTerms); builder.startObject(FieldStrings.TERMS); TermsEnum termIter = curTerms.iterator(); BoostAttribute boostAtt = termIter.attributes().addAttribute(BoostAttribute.class); for (int i = 0; i < curTerms.size(); i++) { buildTerm(builder, spare, curTerms, termIter, boostAtt); } builder.endObject(); builder.endObject(); }
/** * Returns the related attributes, the returned {@link AttributeSource} * is shared with the delegate {@code TermsEnum}. */ @Override public AttributeSource attributes() { return tenum.attributes(); }
/** * Returns the related attributes, the returned {@link AttributeSource} * is shared with the delegate {@code TermsEnum}. */ @Override public AttributeSource attributes() { return tenum.attributes(); }
@Override public AttributeSource attributes() { return in.attributes(); }
@Override // make it synchronized here, to prevent double lazy init public synchronized AttributeSource attributes() { return super.attributes(); }
@Override // make it synchronized here, to prevent double lazy init public synchronized AttributeSource attributes() { return super.attributes(); }
@Override public AttributeSource attributes() { return in.attributes(); }
/** * Returns the related attributes, the returned {@link AttributeSource} * is shared with the delegate {@code TermsEnum}. */ @Override public AttributeSource attributes() { return tenum.attributes(); }
@Override // make it synchronized here, to prevent double lazy init public synchronized AttributeSource attributes() { return super.attributes(); }
/** swap in a new actual enum to proxy to */ protected void setEnum(TermsEnum actualEnum) { this.actualEnum = actualEnum; this.actualBoostAtt = actualEnum.attributes().addAttribute(BoostAttribute.class); }
/** swap in a new actual enum to proxy to */ protected void setEnum(TermsEnum actualEnum) { this.actualEnum = actualEnum; this.actualBoostAtt = actualEnum.attributes().addAttribute(BoostAttribute.class); }
@Override public void setNextEnum(TermsEnum termsEnum) { this.termsEnum = termsEnum; assert compareToLastTerm(null); // lazy init the initial ScoreTerm because comparator is not known on ctor: if (st == null) st = new ScoreTerm(new TermContext(topReaderContext)); boostAtt = termsEnum.attributes().addAttribute(BoostAttribute.class); }
@Override public void setNextEnum(TermsEnum termsEnum) { this.termsEnum = termsEnum; assert compareToLastTerm(null); // lazy init the initial ScoreTerm because comparator is not known on ctor: if (st == null) st = new ScoreTerm(new TermContext(topReaderContext)); boostAtt = termsEnum.attributes().addAttribute(BoostAttribute.class); }
@Override public void setNextEnum(TermsEnum termsEnum) { this.termsEnum = termsEnum; assert compareToLastTerm(null); // lazy init the initial ScoreTerm because comparator is not known on ctor: if (st == null) st = new ScoreTerm(new TermContext(topReaderContext)); boostAtt = termsEnum.attributes().addAttribute(BoostAttribute.class); }
@Override public void setNextEnum(final TermsEnum termsEnum) throws IOException { this.termsEnum = termsEnum; this.termComp = termsEnum.getComparator(); assert this.compareToLastTerm(null); // lazy init the initial ScoreTerm because comparator is not known on ctor: if (st == null) st = new ScoreTerm(this.termComp, new TermContext(topReaderContext)); boostAtt = termsEnum.attributes().addAttribute(BoostAttribute.class); }
@Override public void setNextEnum(final TermsEnum termsEnum) throws IOException { this.termsEnum = termsEnum; this.termComp = termsEnum.getComparator(); assert this.compareToLastTerm(null); // lazy init the initial ScoreTerm because comparator is not known on ctor: if (st == null) st = new ScoreTerm(this.termComp, new TermContext(topReaderContext)); boostAtt = termsEnum.attributes().addAttribute(BoostAttribute.class); }