Class OptXYNode
Object
OptGraphable
OptNode
OptXYNode
- All Implemented Interfaces:
Serializable
,Graphable
,XYNode
,Node
Optimized implementation of XYNode extended from OptNode. Instead of storing an underlying coordinate object, only a
set of (x,y) values are stored eliminating the storage of additional oordinate dimensions.
- Author:
- Justin Deoliveira, Refractions Research Inc, jdeolive@refractions.net
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class OptNode
OptNode.RelatedIterator
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionThis method creates a new Coordinate object upon each call.void
This method strips only the x and y ordinates from the Coordinate object and stores them.Methods inherited from class OptNode
add, getDegree, getEdge, getEdgeArray, getEdges, getEdges, getRelated, remove, setDegree
Methods inherited from class OptGraphable
getCount, getID, getObject, isVisited, setCount, setID, setObject, setVisited
Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface Graphable
getCount, getID, getObject, getRelated, isVisited, setCount, setID, setObject, setVisited
-
Constructor Details
-
OptXYNode
public OptXYNode()
-
-
Method Details
-
getCoordinate
This method creates a new Coordinate object upon each call.- Specified by:
getCoordinate
in interfaceXYNode
- Returns:
- A coordinate.
- See Also:
-
setCoordinate
This method strips only the x and y ordinates from the Coordinate object and stores them.- Specified by:
setCoordinate
in interfaceXYNode
- Parameters:
c
- A coordinate.- See Also:
-