public class LengthNormModifier
extends java.lang.Object
NOTE: This only works if you do not use field/document boosts in your index.
| Constructor and Description |
|---|
LengthNormModifier(Directory d,
Similarity s)
Deprecated.
Constructor for code that wishes to use this class progaomatically.
|
| Modifier and Type | Method and Description |
|---|---|
static void |
main(java.lang.String[] args)
Deprecated.
Command Line Execution method.
|
void |
reSetNorms(java.lang.String field)
Deprecated.
Resets the norms for the specified field.
|
public LengthNormModifier(Directory d, Similarity s)
d - The Directory to modifys - The Similarity to use in reSetNormspublic static void main(java.lang.String[] args)
throws java.io.IOException
Usage: LengthNormModifier /path/index package.SimilarityClassName field1 field2 ...
java.io.IOExceptionpublic void reSetNorms(java.lang.String field)
throws java.io.IOException
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.
field - the field whose norms should be resetjava.io.IOExceptionCopyright © 2000-2016 Apache Software Foundation. All Rights Reserved.