Completed implementation for DGEdge and DGNode. Haven't tested these classes yet.