-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathCatalogo.h
More file actions
49 lines (42 loc) · 1 KB
/
Copy pathCatalogo.h
File metadata and controls
49 lines (42 loc) · 1 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
/** Arquivo Catalogo.h para o programa do catalogo de filmes.
* Terceiro trabalho avaliado EEL670 2022.2
* Aluno: Luis Guilherme Neri Ferreira */
#include <iostream>
#include <ostream>
#include <vector>
#include <string>
using namespace std;
#ifndef CATALOGO_H
#define CATALOGO_H
struct Filme
{
string nome;
string produtora;
double nota;
bool operator< (Filme*);
bool operator> (Filme*);
bool operator== (Filme*);
bool operator< (double);
bool operator> (double);
};
class Catalogo
{
public:
vector<Filme*> getFilmes();
unsigned getMaxFilmes();
Catalogo(int);
int operator+= (Filme*);
void operator+= (vector<Filme*>);
int operator-= (Filme*);
int operator() (string);
int operator() (string, string, double);
int operator() (string, string, string);
int melhorFilme();
private:
vector<Filme*> filmes;
unsigned maxFilmes;
};
ostream& operator<< (ostream&, Catalogo*);
ostream& operator<< (ostream&, Filme*);
istream& operator>> (istream&, Filme*);
#endif