public class OptEdge extends OptGraphable implements Edge
Edge
,
Serialized FormModifier and Type | Class and Description |
---|---|
class |
OptEdge.RelatedIterator |
EQUAL_NODE_ORIENTATION, OPPOSITE_NODE_ORIENTATION, UNEQUAL_NODE_ORIENTATION
Constructor and Description |
---|
OptEdge(OptNode nodeA,
OptNode nodeB)
Constructs a new optimized edge.
|
Modifier and Type | Method and Description |
---|---|
int |
compareNodes(Edge other)
Compares the node orientation of the edge with another edge.
|
Node |
getNodeA()
Returns the A node of the edge.
|
Node |
getNodeB()
Returns the B node of the edge.
|
Node |
getOtherNode(Node node)
Returns one of the two nodes of an edge.
|
Iterator |
getRelated()
Returns an iterator over any related components.
|
void |
reverse()
Reverses the node orientation of the edge.
|
getCount, getID, getObject, isVisited, setCount, setID, setObject, setVisited
public Node getNodeA()
Edge
getNodeA
in interface Edge
Edge.getNodeA()
public Node getNodeB()
Edge
getNodeB
in interface Edge
Edge.getNodeB()
public Node getOtherNode(Node node)
Edge
getOtherNode
in interface Edge
node
- The node opposite of the node to return.Edge.getOtherNode(Node)
public void reverse()
Edge
reverse
in interface Edge
Edge.reverse()
public int compareNodes(Edge other)
Edge
compareNodes
in interface Edge
Edge.compareNodes(Edge)
public Iterator getRelated()
Graphable
getRelated
in interface Graphable
Graphable.getRelated()
Copyright © 1996–2019 Geotools. All rights reserved.