Examples of Synonym


Examples of nl2sql.lexicon.Synonym

                String valu = current;
                // Xử lý ngữ nghĩa trước
                int tagPos = tag.getTag(Tag.get(i));
                if(tagPos!= -1){
                    attr = tag.getCol(db, tagPos);
                    Synonym sy = new Synonym();
                    ArrayList<String> syn = sy.getSynonym(current);
                    if(!syn.isEmpty()){
                        valu = syn.get(0);
                    } else{
                        valu = current;
                    }
View Full Code Here

Examples of org.biojava.ontology.Synonym

        sb.append("\nis_obsolete: true");
      }
      for (Object synonym : term.getSynonyms()) {
        sb.append("\nsynonym: ");
        if (synonym instanceof Synonym) {
          Synonym s = (Synonym) synonym;
          StringTools.append(sb, "\"", s.getName(), "\" [");
          if (s.getCategory() != null) {
            sb.append(s.getCategory());
          }
          sb.append(']');
        } else {
          sb.append(synonym);
        }
View Full Code Here

Examples of org.biojava.ontology.Synonym

    public Synonym[] getSynonyms() {
      Object synonyms[] = term.getSynonyms();
      if ((synonyms == null) || (synonyms.length == 0)) {
        return new Synonym[0];
      }
      Synonym syn[] = new Synonym[synonyms.length];
      for (int i = 0; i < synonyms.length; i++) {
        syn[i] = (Synonym) synonyms[i];
      }
      return syn;
    }
View Full Code Here

Examples of org.biojava.ontology.Synonym

         */
        if (value.length() == 0)
          throw new ParseException("Tag found with no value "+ line);

        if ( isSynonym(name)){
          Synonym synonym = parseSynonym(name,value);
          triggerNewSynonym(synonym);
        } else {
          //System.out.println("new key:" + name + " " + value);
          triggerNewKey(name,value);
        }
View Full Code Here

Examples of org.biojava.ontology.Synonym

      } else
        throw new ParseException("Expected dbxref list,"
            + " instead found " + token +   line );
    }

    Synonym synonym = new Synonym();
    synonym.setScope(scope);
    synonym.setCategory(catID);
    synonym.setName(p.str);
    //System.out.println("SYNONYM: " + p.str +" " + synonym.getCategory() + " " + synonym.getScope());

    Map<String,Object>[] refs = getDbxrefList(value,defIndex + 1, value.length());
   
    // set the refs in the synonym
View Full Code Here

Examples of org.biojava.ontology.Synonym

        sb.append("\nis_obsolete: true");
      }
      for (Object synonym : term.getSynonyms()) {
        sb.append("\nsynonym: ");
        if (synonym instanceof Synonym) {
          Synonym s = (Synonym) synonym;
          StringTools.append(sb, "\"", s.getName(), "\" [");
          if (s.getCategory() != null) {
            sb.append(s.getCategory());
          }
          sb.append(']');
        } else {
          sb.append(synonym);
        }
View Full Code Here

Examples of org.biojava.ontology.Synonym

    public Synonym[] getSynonyms() {
      Object synonyms[] = term.getSynonyms();
      if ((synonyms == null) || (synonyms.length == 0)) {
        return new Synonym[0];
      }
      Synonym syn[] = new Synonym[synonyms.length];
      for (int i = 0; i < synonyms.length; i++) {
        syn[i] = (Synonym) synonyms[i];
      }
      return syn;
    }
View Full Code Here

Examples of org.biojava.ontology.Synonym

        sb.append("\nis_obsolete: true");
      }
      for (Object synonym : term.getSynonyms()) {
        sb.append("\nsynonym: ");
        if (synonym instanceof Synonym) {
          Synonym s = (Synonym) synonym;
          StringTools.append(sb, "\"", s.getName(), "\" [");
          if (s.getCategory() != null) {
            sb.append(s.getCategory());
          }
          sb.append(']');
        } else {
          sb.append(synonym);
        }
View Full Code Here

Examples of org.biojava.ontology.Synonym

    public Synonym[] getSynonyms() {
      Object synonyms[] = term.getSynonyms();
      if ((synonyms == null) || (synonyms.length == 0)) {
        return new Synonym[0];
      }
      Synonym syn[] = new Synonym[synonyms.length];
      for (int i = 0; i < synonyms.length; i++) {
        syn[i] = (Synonym) synonyms[i];
      }
      return syn;
    }
View Full Code Here

Examples of org.mizartools.dli.Synonym

    SymbolId symbolId1 = Adapter.getSymbolId1(pattern);
    Loci loci = Adapter.getLoci(abstractSignature, pattern.getArgTypes());
    Format format = Adapter.getFormat(pattern.getFormat());
    Visible visible = Adapter.getVisible(pattern.getVisible());
    Constructor constructor = Adapter.getConstructor(abstractSignature, pattern);
    Synonym synonym = null;
    Antonym antonym = null;
    org.mizartools.system.xml.Pattern.Kind kind = pattern.getKind();
    switch (kind) {
    case M :
      if (pattern.getRedefnr() != null) synonym = new Synonym();
      Abbreviation abbreviation = Adapter.getAbbreviation(abstractSignature, pattern.getExpansion());
      itemDefinition = new ModeNotation(symbolId1, loci, format, visible, constructor, abbreviation, synonym);
      itemType = ItemType.modenot;
      break;
    case R :
      if (pattern.getAntonymic() != nullantonym = new Antonym();
      if (pattern.getRedefnr() != null) synonym = new Synonym();
      if (antonym != null && synonym != null) synonym = null;
      itemDefinition = new PredicateNotation(symbolId1, loci, format, visible, constructor, antonym, synonym);
      itemType = ItemType.prednot;
      break;
    case K :
      if (pattern.getRedefnr() != null) synonym = new Synonym();
      SymbolId symbolId2 = Adapter.getSymbolId2(pattern);
      itemDefinition = new FunctorNotation(symbolId1, symbolId2, loci, format, visible, constructor, synonym);
      itemType = ItemType.funcnot;
      break;
    case V :
      if (pattern.getAntonymic() != nullantonym = new Antonym();
      if (antonym == null && pattern.getRedefnr() != null) synonym = new Synonym();
      itemDefinition = new AttributeNotation(symbolId1, loci, format, visible, constructor, antonym, synonym);
      itemType = ItemType.attrnot;
      break;
    case G :
      itemDefinition = new AggregateNotation(symbolId1, loci, format, visible, constructor, synonym);
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.