Example #1
0
  /** Compute the labelling for all dirEdges in this star, as well as the overall labelling */
  public void computeLabelling(GeometryGraph[] geom) {
    // Debug.print(this);
    super.computeLabelling(geom);

    // determine the overall labelling for this DirectedEdgeStar
    // (i.e. for the node it is based at)
    label = new Label(Location.NONE);
    for (Iterator it = iterator(); it.hasNext(); ) {
      EdgeEnd ee = (EdgeEnd) it.next();
      Edge e = ee.getEdge();
      Label eLabel = e.getLabel();
      for (int i = 0; i < 2; i++) {
        int eLoc = eLabel.getLocation(i);
        if (eLoc == Location.INTERIOR || eLoc == Location.BOUNDARY)
          label.setLocation(i, Location.INTERIOR);
      }
    }
    // Debug.print(this);
  }
 @Override
 public void print(final PrintStream out) {
   super.print(out);
   out.print(" " + this.depth[Position.LEFT] + "/" + this.depth[Position.RIGHT]);
   out.print(" (" + getDepthDelta() + ")");
   // out.print(" " + this.hashCode());
   // if (next != null) out.print(" next:" + next.hashCode());
   if (this.isInResult) {
     out.print(" inResult");
   }
 }
Example #3
0
 /** Add the edge to the list of edges at this node */
 public void add(EdgeEnd e) {
   // Assert: start pt of e is equal to node point
   edges.insert(e);
   e.setNode(this);
 }