Class GeneDocumentFactory


  • public class GeneDocumentFactory
    extends java.lang.Object
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      GeneDocument createGeneDocument​(org.apache.uima.jcas.JCas jCas, java.util.Map<java.lang.String,​java.util.regex.Matcher> entityMappingTypes, java.util.function.Function<de.julielab.jcore.types.EntityMention,​org.apache.commons.lang3.tuple.Pair<java.lang.String,​org.apache.lucene.search.BooleanQuery>> contextFun)
      Creates a document by setting all required information from the jCas.
      static GeneDocumentFactory getInstance()  
      static void initialize​(GeneMapping mapper)  
      • Methods inherited from class java.lang.Object

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

      • createGeneDocument

        public GeneDocument createGeneDocument​(org.apache.uima.jcas.JCas jCas,
                                               java.util.Map<java.lang.String,​java.util.regex.Matcher> entityMappingTypes,
                                               java.util.function.Function<de.julielab.jcore.types.EntityMention,​org.apache.commons.lang3.tuple.Pair<java.lang.String,​org.apache.lucene.search.BooleanQuery>> contextFun)
                                        throws org.apache.uima.analysis_engine.AnalysisEngineProcessException

        Creates a document by setting all required information from the jCas.

        Items added are:

        • Title text
        • Text body
        • Sentences
        • PoS tags
        • Chunks
        • Acronyms
        • MeSH Headings (from which species headings will be recognized)
        • Species text mentions
        • The genes, according to the entityMappingTypes. This is a mapping from qualified UIMA types to matchers that need to match the EntityMentions' specificType feature in order for the EntityMention to be used as a gene mention.

        Parameters:
        jCas - The JCas to create the GeneDocument form.
        entityMappingTypes - This is a mapping from qualified UIMA types to matchers that need to match the EntityMentions' specificType feature in order for the EntityMention to be used as a gene mention.
        contextFun - A function that delivers the context information for each gene mention.
        Throws:
        org.apache.uima.analysis_engine.AnalysisEngineProcessException