-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathVideo.cpp
More file actions
119 lines (105 loc) · 2.13 KB
/
Copy pathVideo.cpp
File metadata and controls
119 lines (105 loc) · 2.13 KB
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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
/*
* Streaming Service Modeling Proyect
* Rommel T.
*/
/*
* Definition of Video class
*/
#include "Video.h"
/**
* Constructor for the Video class with two parameters
*
* @param string id: the ID of the video, string name_: the name of the video
* @return Video object
*/
Video::Video(string id, string name_){
this->id = id;
setName(name_);
}
/**
* Constructor for the Video class with five parameters.
* @param string id: the ID of the video, string name_: the name of the video
* int length_: the length of the video
* string genres_: the genre of the video
* int rating_: the rating of the video
* @return Video object
*/
Video::Video(string id, string name_, int length_, string genres_, int rating_){
this->id = id;
setName(name_);
setLength(length_);
setGenre(genres_);
setRating(rating_);
}
/**
* Retrieves the ID of the video.
* @param
* @return string: the ID of the video
*/
string Video::getId(){
return id;
}
/**
* Sets the name of the video.
* @param string name: the name of the video
* @return
*/
void Video::setName(string name){
this->name = name;
}
/**
* Retrieves the name of the video.
* @param
* @return string: the name of the video
*/
string Video::getName(){
return name;
}
/**
* Sets the length of the video.
* @param int length: the length of the video
* @return
*/
void Video::setLength(int length){
this->length = length;
}
/**
* Retrieves the length of the video.
* @param
* @return float: the length of the video
*/
float Video::getLength(){
return length;
}
/**
* Sets the genre of the video.
* @param string genre: the genre of the video
* @return
*/
void Video::setGenre(string genre){
this->genre = genre;
}
/**
* Retrieves the genre of the video.
* @param
* @return string: the genre of the video
*/
string Video::getGenre(){
return genre;
}
/**
* Sets the rating of the video.
* @param int rating: the rating of the video
* @return
*/
void Video::setRating(int rating){
this->rating = rating;
}
/**
* Retrieves the rating of the video.
* @param
* @return int: the rating of the video
*/
int Video::getRating(){
return rating;
}