
org.codelibs.elasticsearch.dynarank.script.DynaRankScript Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of elasticsearch-dynarank Show documentation
Show all versions of elasticsearch-dynarank Show documentation
This plugin provides a feature to re-rank a search result at the search time.
The newest version!
package org.codelibs.elasticsearch.dynarank.script;
import java.util.Map;
import org.elasticsearch.script.ScriptContext;
import org.elasticsearch.search.SearchHit;
public abstract class DynaRankScript {
protected final Map params;
public DynaRankScript(final Map params) {
this.params = params;
}
public Map getParams() {
return params;
}
public abstract SearchHit[] execute(final SearchHit[] searchHits);
public interface Factory {
DynaRankScript newInstance(final Map params);
}
public static final String[] PARAMETERS = {"searchHits"};
public static final ScriptContext CONTEXT = new ScriptContext<>("dynarank", Factory.class);
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy