Class IndexFacts.Session

  • Enclosing class:
    IndexFacts

    public class IndexFacts.Session
    extends java.lang.Object
    Create an instance of this to look up index facts with a given query. Note that if the model.source or model.restrict parameters of the query is changed another session should be created. This is immutable.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.util.List<java.lang.String> documentTypes()
      Returns an immutable list of the document types this has resolved to
      java.lang.String getCanonicName​(java.lang.String indexName)
      Returns the canonical form of the index name (Which may be the same as the input).
      Index getIndex​(java.lang.String indexName)
      Returns the index for this name.
      Index getIndex​(java.lang.String indexName, java.lang.String documentType)
      Returns an index given from a given search definition
      java.util.Collection<Index> getIndexes​(java.lang.String documentType)
      Returns all the indexes of a given search definition
      boolean isIndex​(java.lang.String indexName)
      Returns whether the given name is an index.
      java.lang.String toString()  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Method Detail

      • getIndex

        public Index getIndex​(java.lang.String indexName)
        Returns the index for this name.
        Parameters:
        indexName - the name of the index. If this is null or empty the index named "default" is returned
        Returns:
        the index best matching the input parameters or the nullIndex (never null) if none is found
      • getIndex

        public Index getIndex​(java.lang.String indexName,
                              java.lang.String documentType)
        Returns an index given from a given search definition
      • getIndexes

        public java.util.Collection<Index> getIndexes​(java.lang.String documentType)
        Returns all the indexes of a given search definition
      • getCanonicName

        public java.lang.String getCanonicName​(java.lang.String indexName)
        Returns the canonical form of the index name (Which may be the same as the input).
        Parameters:
        indexName - index name or alias
      • isIndex

        public boolean isIndex​(java.lang.String indexName)
        Returns whether the given name is an index.
        Parameters:
        indexName - index name candidate
      • documentTypes

        public java.util.List<java.lang.String> documentTypes()
        Returns an immutable list of the document types this has resolved to
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object