code: private String computeTypeFromMappingSource(String source)
        throws MtasParserException {
      if (source.equals(MtasParserMapping.SOURCE_OWN)) {
        return null;
      } else if (source.equals(MtasParserMapping.SOURCE_ANCESTOR_GROUP)) {
        return MAPPING_TYPE_GROUP;
      } else if (source
          .equals(MtasParserMapping.SOURCE_ANCESTOR_GROUP_ANNOTATION)) {
        return MAPPING_TYPE_GROUP_ANNOTATION;
      } else if (source.equals(MtasParserMapping.SOURCE_ANCESTOR_WORD)) {
        return MAPPING_TYPE_WORD;
      } else if (source
          .equals(MtasParserMapping.SOURCE_ANCESTOR_WORD_ANNOTATION)) {
        return MAPPING_TYPE_WORD_ANNOTATION;
      } else if (source.equals(MtasParserMapping.SOURCE_ANCESTOR_RELATION)) {
        return MAPPING_TYPE_RELATION;
      } else if (source
          .equals(MtasParserMapping.SOURCE_ANCESTOR_RELATION_ANNOTATION)) {
        return MAPPING_TYPE_RELATION_ANNOTATION;
      } else {
        throw new MtasParserException("unknown source " + source);
      }
    }
docs: Compute type from mapping source.
  
  @param source the source
  @return the string
  @throws MtasParserException the mtas parser exception