Class TypeTemplate

  • Direct Known Subclasses:
    FeatureTemplate

    public class TypeTemplate
    extends Object
    Represents a Template for a type which Contains a List of Feature Templates and all necessary Informations to build a concrete Type.
    Author:
    Weigel
    • Field Detail

      • fullClassName

        protected String fullClassName
      • externalParser

        protected boolean externalParser
      • partOfDocuments

        protected List<Integer> partOfDocuments
      • multipleInstances

        protected boolean multipleInstances
      • inlineAnnotation

        protected boolean inlineAnnotation
    • Constructor Detail

      • TypeTemplate

        public TypeTemplate()
        Creates a new instance of a TypeTemplate
    • Method Detail

      • addFeature

        public void addFeature​(FeatureTemplate feature)
        adds a FeatureTemplate to the List
        Parameters:
        feature -
      • getFeatures

        public List<FeatureTemplate> getFeatures()
        Returns:
        the List of all FeatureTemplates
      • setFeatures

        public void setFeatures​(List<FeatureTemplate> features)
        Parameters:
        features - the features to set
      • getFullClassName

        public String getFullClassName()
        Returns:
        the fullClassName
      • setFullClassName

        public void setFullClassName​(String fullClassName)
        Parameters:
        fullClassName - the fullClassName to set
      • setParser

        public void setParser​(String trim)
                       throws org.apache.uima.collection.CollectionException
        Overrides the parser and sets an external parser
        Parameters:
        trim - a String containing the full qualified Classname of the parser
        Throws:
        org.apache.uima.collection.CollectionException
      • getParser

        public TypeParser getParser()
        Returns:
        the externalParser
      • getXPaths

        public List<String> getXPaths()
        Returns:
        the valueXPath
      • addAdditionalData

        public void addAdditionalData​(String value,
                                      int index)
      • getAdditionalData

        public String[] getAdditionalData()
      • addPartOfDocumentText

        public void addPartOfDocumentText​(int partOfDocumentId)
      • getOffsetPartIDs

        public int[] getOffsetPartIDs()
        returns the first and the last of partOfDocument ids that should be covered by this annotation; that is, the begin of this annotation should be at the begin of the first returned part and the end should be the end of the second returned part.
        Returns:
        int[] ( int[0]->begin index, int[1] -> endIndex )
      • addXPath

        public void addXPath​(String xpath)
      • isMultipleInstances

        public boolean isMultipleInstances()
      • isInlineAnnotation

        public boolean isInlineAnnotation()
      • setMultipleInstances

        public void setMultipleInstances​(boolean b)
      • setInlineAnnotation

        public void setInlineAnnotation​(boolean inlineAnnotation)