-
Notifications
You must be signed in to change notification settings - Fork 1
/
ActorEdge.hpp
42 lines (35 loc) · 962 Bytes
/
ActorEdge.hpp
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
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
/**
* Name: Rui Deng
* Dadong Jing
* Data: Mar 10, 2016
* Overview: this file is to implement the edge and its functionality
* of graph
* Assignment number: PA4
*/
#ifndef ACTOREDGE_HPP
#define ACTOREDGE_HPP
using namespace std;
//initialize actor and movie class to avoid not class type case
class ActorNode;
class Movie;
/**
* edge class to store two actors in two ends of the edge and a movie that
* two actors both appear
*/
class ActorEdge
{
public:
//two actors and one movie as memeber variables
ActorNode* startNode;
ActorNode* endNode;
Movie* movieName;
/**
* constructor taking in three parameters and initialize all members
* Param: starting actor node, ending actor node,
* and their movie connection
*/
ActorEdge(ActorNode* start,
ActorNode* end,
Movie* movie) : startNode(start),endNode(end),movieName(movie){};
};
#endif //ACTOREDGE_HPP