|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Object MapSegment
public class MapSegment
Field Summary | |
---|---|
protected MapNode |
endNode
|
protected MapNode |
startNode
|
Constructor Summary | |
---|---|
MapSegment(MapNode startNode,
MapNode endNode)
|
Method Summary | |
---|---|
VectorXZ |
getCenter()
returns the center of the line |
VectorXZ |
getDirection()
returns a normalized vector indicating the line's horizontal direction |
MapNode |
getEndNode()
|
LineSegmentXZ |
getLineSegment()
|
MapNode |
getOtherNode(MapNode node)
|
VectorXZ |
getRightNormal()
returns a the result of applying VectorXZ.rightNormal()
to vector returned by getDirection() |
List<MapNode> |
getStartEndNodes()
|
MapNode |
getStartNode()
|
boolean |
isConnectedTo(MapArea other)
returns true if this MapSegment shares a node with a MapArea |
boolean |
isConnectedTo(MapSegment other)
returns true if this MapSegment shares a node with another MapSegment |
boolean |
sharesBothNodes(MapSegment other)
returns true if this MapSegment shares both nodes with another MapSegment |
Methods inherited from class Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected final MapNode startNode
protected final MapNode endNode
Constructor Detail |
---|
public MapSegment(MapNode startNode, MapNode endNode)
Method Detail |
---|
public MapNode getStartNode()
public MapNode getEndNode()
public MapNode getOtherNode(MapNode node)
public List<MapNode> getStartEndNodes()
public LineSegmentXZ getLineSegment()
public VectorXZ getDirection()
public VectorXZ getRightNormal()
VectorXZ.rightNormal()
to vector returned by getDirection()
public VectorXZ getCenter()
public boolean isConnectedTo(MapSegment other)
public boolean isConnectedTo(MapArea other)
public boolean sharesBothNodes(MapSegment other)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |