Revision 8004 trunk/extensions/extGraph_predes/src/com/iver/cit/gvsig/topology/geomgraph/SnappingPlanarGraph.java
SnappingPlanarGraph.java | ||
---|---|---|
15 | 15 |
import com.vividsolutions.jts.geomgraph.DirectedEdgeStar; |
16 | 16 |
import com.vividsolutions.jts.geomgraph.Edge; |
17 | 17 |
import com.vividsolutions.jts.geomgraph.EdgeEnd; |
18 |
import com.vividsolutions.jts.geomgraph.EdgeEndStar; |
|
18 | 19 |
import com.vividsolutions.jts.geomgraph.Label; |
19 | 20 |
import com.vividsolutions.jts.geomgraph.Node; |
20 | 21 |
import com.vividsolutions.jts.geomgraph.NodeFactory; |
... | ... | |
47 | 48 |
public static void linkResultDirectedEdges(Collection nodes) { |
48 | 49 |
for (Iterator nodeit = nodes.iterator(); nodeit.hasNext();) { |
49 | 50 |
Node node = (Node) nodeit.next(); |
50 |
((DirectedEdgeStar) node.getEdges()).linkResultDirectedEdges(); |
|
51 |
DirectedEdgeStar edgeStar = (DirectedEdgeStar) node.getEdges(); |
|
52 |
edgeStar.linkResultDirectedEdges(); |
|
51 | 53 |
} |
52 | 54 |
} |
53 | 55 |
|
... | ... | |
242 | 244 |
Node node = (Node) it.next(); |
243 | 245 |
System.out.println(node.getCoordinate()); |
244 | 246 |
System.out.println(node.getLabel()); |
245 |
node.getEdges().print(System.out); |
|
247 |
List edges = node.getEdges().getEdges(); |
|
248 |
for(int z = 0; z < edges.size(); z++){ |
|
249 |
EdgeEnd ee = (EdgeEnd) edges.get(z); |
|
250 |
Label eeL = ee.getLabel(); |
|
251 |
System.out.println(ee.toString() + "," + eeL.toString()); |
|
252 |
} |
|
246 | 253 |
} |
247 | 254 |
// nodes.dump(); |
248 | 255 |
} |
Also available in: Unified diff