Removed edge.java and cleaned up code