added constructor for Graph from GraphParser
added printGraph