예제 #1
0
  protected Target[] ownedTargets(Sign tl, int pos, Node des, boolean light) {
    // This method will determine to which destinations you can go starting at this source
    // represented in this QEntry

    CountEntry dummy = new CountEntry(tl, pos, des, light, tl, pos);
    Target[] ownedtargets;
    Vector candidate_targets;
    candidate_targets = new Vector();

    // Use the count table to sort this out, we need all Targets from
    // Only the elements in the count table are used, other  just give a P

    Enumeration _enum = count.elements();
    while (_enum.hasMoreElements()) {
      CountEntry current_entry = (CountEntry) _enum.nextElement();
      if (current_entry.sameSource(dummy) != 0) {
        candidate_targets.addElement(new Target(current_entry.tl_new, current_entry.pos_new));
      }
    }
    ownedtargets = new Target[candidate_targets.size()];
    candidate_targets.copyInto(ownedtargets);
    return ownedtargets;
  }
예제 #2
0
 public void loadSecondStage(Dictionary dictionaries)
     throws XMLInvalidInputException, XMLTreeException {
   XMLUtils.loadSecondStage(count.elements(), dictionaries);
   // XMLUtils.loadSecondStage(p_table.elements(),dictionaries);
   System.out.println("SL1 second stage load finished.");
 }