Ejemplo n.º 1
0
 private void initSetterMap() {
   Method setter = null;
   setter = getSetter("setKeyword", String.class);
   setMethodMap.put("keyword", setter);
   setter = getSetter("setParents", DefaultPersistibleList.class);
   setMethodMap.put("parentKeyword", setter);
   setter = getSetter("setDescribedInstances", DefaultPersistibleList.class);
   setMethodMap.put("describedInstances", setter);
   //  				setter = getSetter("getSubordinateKeywords");
   //  				getMethodMap.put("subordinateKeywords", setter);
 }
Ejemplo n.º 2
0
 private void initGetterMap() {
   Method getter = null;
   getter = getGetter("getKeyword");
   getMethodMap.put("keyword", getter);
   getter = getGetter("getParents");
   getMethodMap.put("parentKeyword", getter);
   getter = getGetter("getDescribedInstances");
   getMethodMap.put("describedInstances", getter);
   // 		getter = getGetter("getSubordinateKeywords");
   // 				getMethodMap.put("subordinateKeywords", getter);
 }
Ejemplo n.º 3
0
  private void addKeyword(Hashtable table, Keyword word, Keyword parent) {
    boolean recurse = true;

    if (table.containsKey(word)) recurse = false;

    if (parent == null) table.put(word, String.valueOf(-1));
    else table.put(word, parent);

    if (recurse) {
      Iterator it = word.getChildren().iterator();
      while (it.hasNext()) {
        addKeyword(table, (Keyword) it.next(), word);
      }
    }
  }