I have a simple UNDIRECTED Graph G, and want to reverse an edge if a certain condition is true. The following code gives an error that the EdgeElement constructor is inaccessible:
if(dfsNum[source->index()]>dfsNum[target->index()]){
EdgeElement ee(target, source, target->firstAdj(), source->firstAdj(), e->index());
e = ee.theEdge();
}
Is this the correct way of doing what I am doing?
IMPORTANT EDIT: My bad. I do not have to reverse the edge, I have to direct it.