private Vertex updateNode(String currentNodeKey) {
for (Iterator nodeIterator = outputGraph.getVertices().iterator();
nodeIterator.hasNext();) {
Vertex currentVertex = (Vertex) nodeIterator.next();
if (currentVertex.getUserDatum("label").toString()
.equalsIgnoreCase(currentNodeKey)) {
int currentVertexStrength =
((Integer) currentVertex.getUserDatum("strength")).intValue();
currentVertex.setUserDatum("strength", new Integer(++currentVertexStrength),
new UserDataContainer.CopyAction.Shared());
return currentVertex;
}
}
return new DirectedSparseVertex();