#ifndef __GRAPH_H__ #define __GRAPH_H__ #include #include #include #include #include #include #include "vertex.h" #include "vertexlist.h" #include "edge.h" #include "edgelist.h" #include "tovert.h" using std::vector; using std::string; using std::cin; using std::cout; using std::ostream; using std::endl; using std::setw; using std::setfill; class graph { private: vertexlist vtxlst; edgelist edglst; bool directed; vector > adjList; vector > adjMatrix; public: graph(); graph(bool dir); void displayVertices() const; void displayEdges() const; unsigned int getVertexListSize() const; unsigned int getEdgeListSize() const; void displayAdjacencyList() const; void displayAdjacencyMatrix() const; void shortestPath(const char* src, const char* dest); int addVertex(const char* vert); bool addEdge(const char* src, const char* dest, double weight, bool dir=false); }; #endif