Class ScriptedSimilarity


public final class ScriptedSimilarity
A Similarity implementation that allows scores to be scripted.
  • Nested Class Summary

    Nested Classes 
    Modifier and Type Class Description
    static class  ScriptedSimilarity.Doc
    Statistics that are specific to a document.
    static class  ScriptedSimilarity.Field
    Statistics that are specific to a given field.
    static class  ScriptedSimilarity.Query
    Scoring factors that come from the query.
    static class  ScriptedSimilarity.Term
    Statistics that are specific to a given term.

    Nested classes/interfaces inherited from class
  • Constructor Summary

    Constructor Description
    ScriptedSimilarity​(java.lang.String weightScriptString, SimilarityWeightScript.Factory weightScriptFactory, java.lang.String scriptString, SimilarityScript.Factory scriptFactory, boolean discountOverlaps)
    Sole constructor.
  • Method Summary

    Modifier and Type Method Description
    long computeNorm​(org.apache.lucene.index.FieldInvertState state) scorer​(float boost, collectionStats, termStats)  
    java.lang.String toString()  

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
  • Constructor Details

  • Method Details

    • toString

      public java.lang.String toString()
      toString in class java.lang.Object
    • computeNorm

      public long computeNorm​(org.apache.lucene.index.FieldInvertState state)
      Specified by:
      computeNorm in class
    • scorer

      public scorer​(float boost, collectionStats, termStats)
      Specified by:
      scorer in class