next up previous index
Next: Version number Up: Weighted Graphs Previous: The arcs iterator   Index

Other methods

There are a few other simple methods that can be useful.
public int nrNodes() {
    return nrNodes;
}

public int nrArcs() {
    return nrArcs;
}
It may also be useful to know whether the graph contains a certain node, identified by its label.
public boolean contains(Object label) {
    return nodeMap.contains(label);
}



Subsections

Peter Williams 2005-06-07