-
Notifications
You must be signed in to change notification settings - Fork 0
/
person.h
executable file
·71 lines (55 loc) · 2.49 KB
/
person.h
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
#ifndef PERSON_H
#define PERSON_H
#include <QString>
#include "address.h"
#include <QMap>
class Person
{
public:
Person( const QString& first_name,
const QString& last_name,
Address *address,
const QString& personal_code,
const QString& job,
const QString& license,
const QDate & date_of_issue,
const QString& email = "",
const QString& phone = "" );
Person( const QString& first_name,
const QString& last_name,
Address *address,
const QString& personal_code,
const QString& job,
const QString& email = "",
const QString& phone = "" );
Person() {}
~Person();
QString getFirst_name() const { return first_name_; }
QString getLast_name() const { return last_name_; }
Address * getAddress() const { return address_; }
QString getEmail() const { return email_; }
QString getPhone() const { return phone_; }
QString getPersonal_code() const { return personal_code_; }
QString getJob() const { return job_; }
QString getLicense() const { return license_; }
QDate getDateOfIssue() const { return date_of_issue_; }
bool getLicenseValidity() const { return license_validity_; }
QDate getLastNotification() const { return last_notification_; }
void setLicenseValidity(const bool& license_validity) { license_validity_ = license_validity; }
void setLastNotification(const QDate& last_notification) { last_notification_ = last_notification; }
void setLicense(const QString& license, const QDate& date_of_issue, const bool& license_validity = true, const QDate& last_notification = QDate());
bool isSufficient() const;
private:
QString first_name_;
QString last_name_;
Address* address_;
QString email_;
QString phone_;
QString personal_code_;
QString job_;
QString license_;
QDate date_of_issue_;
bool license_validity_;
QDate last_notification_;
};
#endif // PERSON_H