28 apr 2006 kl. 00.30 skrev Marvin Humphrey:
On Apr 27, 2006, at 2:35 PM, karl wettin wrote:
What will be required in the IndexReader? Is it enough to add
getBoost() in the TermEnum? How would the value be sent to the
scorer?
It wouldn't be the TermEnum, it would be a TermDocs subclass. If
we're talking BOOST_PER_POSITION, it would have to be a
TermPositions, and you would getBoost() per position. The
TermScorer would have to accumulate a multiplier for each doc by
repeatedly calling nextPosition(). That algorithm would replace
this line in TermScorer:
Sorry, I did of course mean TermDocs.
score *= normDecoder[norms[doc] & 0xFF]; // normalize for
field
If we're talking NORMS_IN_FREQ, then you'd replace that line with
one call to getBoost() against the TermDocs. (or maybe getNorm?
getMultiplier?)
I'll start there.
Considering I don't have to worry about any index format with the
InstanciatedIndex it should be fairly easy to get it working.
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]