org.apache.lucene.misc
public class LengthNormModifier extends Object
NOTE: This only works if you do not use field/document boosts in your index.
Version: $Id$
Constructor Summary | |
---|---|
LengthNormModifier(Directory d, Similarity s)
Constructor for code that wishes to use this class progaomatically.
|
Method Summary | |
---|---|
static void | main(String[] args)
Command Line Execution method.
|
void | reSetNorms(String field)
Resets the norms for the specified field.
|
Parameters: d The Directory to modify s The Similarity to use in reSetNorms
Usage: LengthNormModifier /path/index package.SimilarityClassName field1 field2 ...
Opens a new IndexReader on the Directory given to this instance, modifies the norms using the Similarity given to this instance, and closes the IndexReader.
Parameters: field the field whose norms should be reset