Class ExploreIndex

  • All Implemented Interfaces:
    java.io.Serializable

    public class ExploreIndex
    extends java.lang.Object
    implements java.io.Serializable
    Implementation of document search functionality with Lucene version 8.7.0. for explore API functionality is provided by this class.
    See Also:
    Serialized Form
    • Constructor Summary

      Constructors 
      Constructor Description
      ExploreIndex()  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.util.Set<Concept> getAllConceptsForWildcard​(org.apache.lucene.search.BooleanQuery.Builder builder)
      Searches for all Concepts in SNOINDEX (wildcard query).
      Concept getConceptDetails​(java.lang.String conceptId)
      Searches given conceptId in the SNOMED CT repository and returns Concept suited for ECL reponse.
      java.util.Set<Concept> getConceptsFromQuery​(org.apache.lucene.search.BooleanQuery.Builder builder)
      Searches for all Concepts having the (attribute-value) relationship stated in query.
      java.util.Set<RelationshipTC> getIsARelationshipsWithCount​(java.lang.String conceptId)
      Searches for the immediate children descriptions.
      java.util.Set<Concept> searchTC​(java.lang.String id)
      Searches given concept id in the SNOMED CT repository.
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • ExploreIndex

        public ExploreIndex()
    • Method Detail

      • searchTC

        public java.util.Set<Concept> searchTC​(java.lang.String id)
                                        throws java.text.ParseException
        Searches given concept id in the SNOMED CT repository. returnLimit/MaxRecords - Maximum number of matching terms to be fetched.

        refsetId - Identifier of Refset from which search is to be done and null if search is to be done from whole SNOMED CT Terminology

        Returns:
        Set of RelationshipTC matching the given Concept ID.
        Throws:
        java.text.ParseException
      • getIsARelationshipsWithCount

        public java.util.Set<RelationshipTC> getIsARelationshipsWithCount​(java.lang.String conceptId)
        Searches for the immediate children descriptions.
        Parameters:
        conceptId - Concept Id whose immediate children to search
        Returns:
        Set of RelationshipTC matching the given Concept ID.
        Throws:
        java.io.IOException - if any error occurs while processing.
        java.text.ParseException
      • getConceptsFromQuery

        public java.util.Set<Concept> getConceptsFromQuery​(org.apache.lucene.search.BooleanQuery.Builder builder)
                                                    throws java.io.IOException,
                                                           java.text.ParseException
        Searches for all Concepts having the (attribute-value) relationship stated in query.
        Parameters:
        builder - BooleanQuery query object (based on the type of attribute - value relationship).
        Returns:
        Set of Concepts.
        Throws:
        java.io.IOException
        java.text.ParseException
        org.apache.lucene.queryparser.classic.ParseException
      • getConceptDetails

        public Concept getConceptDetails​(java.lang.String conceptId)
                                  throws java.io.IOException,
                                         java.text.ParseException,
                                         org.apache.lucene.queryparser.classic.ParseException
        Searches given conceptId in the SNOMED CT repository and returns Concept suited for ECL reponse.
        Parameters:
        conceptId - String search on the basis of given conceptId.
        Returns:
        Object of Concept respected to given conceptId
        Throws:
        java.io.IOException
        java.text.ParseException
        org.apache.lucene.queryparser.classic.ParseException
      • getAllConceptsForWildcard

        public java.util.Set<Concept> getAllConceptsForWildcard​(org.apache.lucene.search.BooleanQuery.Builder builder)
                                                         throws java.io.IOException,
                                                                java.text.ParseException,
                                                                org.apache.lucene.queryparser.classic.ParseException
        Searches for all Concepts in SNOINDEX (wildcard query).
        Parameters:
        builder - BooleanQuery query object (all active concepts).
        Returns:
        Set of Concepts.
        Throws:
        java.io.IOException
        java.text.ParseException
        org.apache.lucene.queryparser.classic.ParseException