Graph using map(STL)

I need to create a graph using the map class. Apparently It should have strings as keys and sets as values. I've never used maps or sets. Here is a line of the file I'm supposed to use:
"43: The Richard Petty Story (1974)/McGavin, Darren/Beery Jr., Noah/Petty, Richard (I)/Jalbert, Pierre/Jones, L.Q./Whittington, Jerry (I)/Browne, Kathie"
The first part is the title of the movie, the rest is the actors (/ delimited). Here is a copy of the provided header file:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
#ifndef GRAPH_H
#define GRAPH_H
#include <string>
#include <map>
#include <set>

using namespace std;

class Graph {
    public:
        Graph();
        Graph(string);
        Graph(const Graph& orig);
        virtual ~Graph();
        void addEdge(string v, string w);
        void adjacentTo(string,
                        set<string>::const_iterator &, 
                        set<string>::const_iterator &);
        void vertices(map<string,set<string> >::const_iterator &,
                      map<string,set<string> >::const_iterator &);
    private:
        map <string, set<string> > ST;
};
#endif
/* GRAPH_H */


I gather that I have to use addEdge to make an edge between the movie and the actor, and then from the actor back to the movie, probably in the constructor. But do I need more than one map? Or will the key be the movie name, with the set being the actor? I'm fairly lost...
Topic archived. No new replies allowed.