Overview | Package | Class | Tree | Deprecated | Index | Help
| JTS Topology Suite version 1.13
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.vividsolutions.jts.geomgraph
Class GeometryGraph

    java.lang.Object
      com.vividsolutions.jts.geomgraph.PlanarGraph
          com.vividsolutions.jts.geomgraph.GeometryGraph

    public class GeometryGraph

extends PlanarGraph

A GeometryGraph is a graph that models a given Geometry

Version:
  1.7

Field Summary

Fields inherited from class com.vividsolutions.jts.geomgraph.PlanarGraph
`edgeEndList, edges, nodes`

Constructor Summary
`GeometryGraph(int argIndex, Geometry parentGeom)`
`GeometryGraph(int argIndex, Geometry parentGeom, BoundaryNodeRule boundaryNodeRule)`

Method Summary
`void` | `addEdge(Edge e)` Add an Edge computed externally.
`void` | `addPoint(Coordinate pt)` Add a point computed externally.
`SegmentIntersector` | `computeEdgeIntersections(GeometryGraph g, LineIntersector li, boolean includeProper)`
`SegmentIntersector` | `computeSelfNodes(LineIntersector li, boolean computeRingSelfNodes)` Compute self-nodes, taking advantage of the Geometry type to minimize the number of intersection tests.
`void` | `computeSplitEdges(java.util.List edgelist)`
`static int` | `determineBoundary(BoundaryNodeRule boundaryNodeRule, int boundaryCount)` This method implements the Boundary Determination Rule for determining whether a component (node or edge) that appears multiple times in elements of a MultiGeometry is in the boundary or the interior of the Geometry The SFS uses the "Mod-2 Rule", which this function implements An alternative (and possibly more intuitive) rule would be the "At Most One Rule": isInBoundary = (componentCount == 1)
`Edge` | `findEdge(LineString line)`
`BoundaryNodeRule` | `getBoundaryNodeRule()`
`java.util.Collection` | `getBoundaryNodes()`
`Coordinate[]` | `getBoundaryPoints()`
`Geometry` | `getGeometry()`
`Coordinate` | `getInvalidPoint()`
`boolean` | `hasTooFewPoints()` This constructor is used by clients that wish to add Edges explicitly, rather than adding a Geometry.
`int` | `locate(Coordinate pt)` Determines the `Location` of the given `Coordinate` in this geometry.

Methods inherited from class com.vividsolutions.jts.geomgraph.PlanarGraph
`add, addEdges, addNode, addNode, find, findEdge, findEdgeEnd, findEdgeInSameDirection, getEdgeEnds, getEdgeIterator, getNodeIterator, getNodes, insertEdge, isBoundaryNode, linkAllDirectedEdges, linkResultDirectedEdges, linkResultDirectedEdges, printEdges`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### GeometryGraph

    public GeometryGraph(int argIndex,
                         Geometry parentGeom)

### GeometryGraph

    public GeometryGraph(int argIndex,
                         Geometry parentGeom,
                         BoundaryNodeRule boundaryNodeRule)

Method Detail

### determineBoundary

    public static int determineBoundary(BoundaryNodeRule boundaryNodeRule,
                                        int boundaryCount)

  This method implements the Boundary Determination Rule for determining whether a component (node or edge) that appears multiple times in elements of a MultiGeometry is in the boundary or the interior of the Geometry
  The SFS uses the "Mod-2 Rule", which this function implements
  An alternative (and possibly more intuitive) rule would be the "At Most One Rule": isInBoundary = (componentCount == 1)

### hasTooFewPoints

    public boolean hasTooFewPoints()

  This constructor is used by clients that wish to add Edges explicitly, rather than adding a Geometry. (An example is BufferOp).

### getInvalidPoint

    public Coordinate getInvalidPoint()

### getGeometry

    public Geometry getGeometry()

### getBoundaryNodeRule

    public BoundaryNodeRule getBoundaryNodeRule()

### getBoundaryNodes

    public java.util.Collection getBoundaryNodes()

### getBoundaryPoints

    public Coordinate[] getBoundaryPoints()

### findEdge

    public Edge findEdge(LineString line)

### computeSplitEdges

    public void computeSplitEdges(java.util.List edgelist)

### addEdge

    public void addEdge(Edge e)

  Add an Edge computed externally. The label on the Edge is assumed to be correct.

### addPoint

    public void addPoint(Coordinate pt)

  Add a point computed externally. The point is assumed to be a Point Geometry part, which has a location of INTERIOR.

### computeSelfNodes

    public SegmentIntersector computeSelfNodes(LineIntersector li,
                                               boolean computeRingSelfNodes)

  Compute self-nodes, taking advantage of the Geometry type to minimize the number of intersection tests. (E.g. rings are not tested for self-intersection, since they are assumed to be valid).

  Parameters:
    `li` - the LineIntersector to use
    `computeRingSelfNodes` - if , intersection checks are optimized to not test rings for self-intersection
  Returns:
    the SegmentIntersector used, containing information about the intersections found

### computeEdgeIntersections

    public SegmentIntersector computeEdgeIntersections(GeometryGraph g,
                                                       LineIntersector li,
                                                       boolean includeProper)

### locate

    public int locate(Coordinate pt)

  Determines the `Location` of the given `Coordinate` in this geometry.

  Parameters:
    `p` - the point to test
  Returns:
    the location of the point in the geometry

Overview | Package | Class | Tree | Deprecated | Index | Help
| JTS Topology Suite version 1.13
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD