Class IndexFacts

java.lang.Object
com.yahoo.prelude.IndexFacts

public class IndexFacts extends Object
NOTE: We are in the process of moving the functionality of this over to SchemaInfo - see if you can use that before adding usage of this. A central repository for information about indices. Standard usage is

 IndexFacts.Session session = indexFacts.newSession(query); // once when starting to process a query
 session.getIndex(indexName).[get index info]
 
Author:
Steinar Knutsen
  • Constructor Details

    • IndexFacts

      public IndexFacts()
    • IndexFacts

      public IndexFacts(IndexModel indexModel)
  • Method Details

    • clustersHavingSearchDefinition

      public List<String> clustersHavingSearchDefinition(String searchDefinitionName)
    • freeze

      public IndexFacts freeze()
      Freeze this to prevent further changes.
      Returns:
      this for chaining
    • hasNGramIndices

      public boolean hasNGramIndices()
      Whether this contains any index which has isNGram()==true. This is free to ask on a frozen instance.
    • isFrozen

      public boolean isFrozen()
      Returns whether it is permissible to update this object
    • getDefaultPosition

      public String getDefaultPosition(String sdName)
    • newSession

      public IndexFacts.Session newSession(Query query)
    • newSession

      public IndexFacts.Session newSession(Collection<String> sources, Collection<String> restrict)
    • newSession

      public IndexFacts.Session newSession(Collection<String> sources, Collection<String> restrict, Set<String> candidateDocumentTypes)