Optimized implementation of DirectedNode. The following optimizations
reduce space and increase performance.
In and Out edge adjacency list stored as arrays of exact size.
Support from removing edges is removed
The related component iterators iterates over the underlying edge
arrays of the node instread of newly created collections.
Using an optimized directed node requires that the size of the in and out
edge adjacency lists be known before its creation.
author: Justin Deoliveira, Refractions Research Inc, jdeolive@refractions.net See Also:DirectedNode
Inner Class :public class RelatedIterator implements Iterator
Constructs a new OptDirectedNode. This constructor does not create
the edge adjacency arrays for the node.
OptDirectedNode
public OptDirectedNode(int indegree, int outdegree)(Code)
Constructs a new OptDirectedNode.
Parameters: indegree - Number of in adjacenct edges to the node. Parameters: outdegree - Number of out adjacent edges to the node.
Sets the in degree of the node. This method builds the in edge adjacency
list of the node.
Parameters: indegree - The in degree / size of in edge array of the node.
Sets the out degree of the node. This method builds the out edge adjacency
list of the node.
Parameters: outdegree - The out degree / size of out edge array of the node.
Methods inherited from org.geotools.graph.structure.opt.OptGraphable