Package edu.pitt.terminology

Examples of edu.pitt.terminology.Terminology.search()


    System.out.println("--");
    // do search
    long time = System.currentTimeMillis();
    for(String text: new String [] {"blue tumor"}){
      System.out.println("searching for: "+text);
      for(Concept c: term.search(text)){
        System.out.println(c.getCode()+" "+c.getName());
        c.initialize();
        c.printInfo(System.out);
        System.out.println(c.getCodes());
      }
View Full Code Here


    Terminology terminology = new IndexFinderTerminology("TIES_Pathology");
    //Terminology terminology = new IndexFinderTerminology("NCI_Thesaurus");
    PathHelper ph = new PathHelper(terminology);
    //ph.createAncestryCache();
    for(String text: Arrays.asList("melanoma","nevus","skin","margin")){
      for(Concept c: terminology.search(text)){
        long t = System.currentTimeMillis();
        // lookup paths
       
        List<ConceptPath> path = ph.getPaths(c);
        t = System.currentTimeMillis()-t;
View Full Code Here

        if(text.matches("CL?\\d+") || text.startsWith("http://")){
          c = terminology.lookupConcept(text.trim());
        }else if("ROOT".equals(text)){
          c = terminology.getRootConcepts();
        }else{
          c = terminology.search(text);
        }
        response = processOutput(c);
      }else if ( action.equals("get_roots")){
        response = processOutput(terminology.getRootConcepts());
      }else if ( action.equals("lookup_concept")){
View Full Code Here

      }else if ( action.equals("set_sources")){
        Source [] src = (Source []) parcel.getPayload();
        terminology.setFilterSources(src);
      }else if ( action.equals("search")){
        String txt = (String) parcel.getPayload();
        tosend = terminology.search(txt);
      }else if ( action.equals("lookup_concept")){
        tosend = terminology.lookupConcept((String) parcel.getPayload());
      }else if ( action.equals("get_sources")){
        tosend = terminology.getSources();
      }else if ( action.equals("get_related_concepts")){
View Full Code Here

    System.out.println("lookup time "+(System.currentTimeMillis()-time));
   
    System.out.println("--- search ---");
   
    time = System.currentTimeMillis();
    Concept [] cs = term.search("melanoma");
    for(Concept i: cs){
      i.printInfo(System.out);
    }
    System.out.println("lookup time "+(System.currentTimeMillis()-time));
  }
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.