-
Notifications
You must be signed in to change notification settings - Fork 0
/
task.cpp
executable file
·94 lines (75 loc) · 1.35 KB
/
task.cpp
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
#include "task.h"
#include <QString>
#include <QDateTime>
Task::Task()
{
}
Task::Task(QString uid):
m_uid(uid)
{
}
Task::Task(QString summ, QString desc):
m_summary(summ), m_description(desc)
{
}
QString Task::getUid()
{
return m_uid;
}
QString Task::getSummary()
{
return m_summary;
}
QString Task::getDescription()
{
return m_description;
}
QString Task::getLocation()
{
return m_location;
}
QDateTime Task::getLastModified()
{
return m_lastModified;
}
QString Task::getClass()
{
return m_class;
}
QString Task::getStatus()
{
return m_status;
}
void Task::setUid(const QString uid)
{
m_uid = QString(uid);
}
void Task::setDescription(const QString desc)
{
m_description = QString(desc);
}
void Task::setSummary(const QString summ)
{
m_summary = QString(summ);
}
void Task::setLocation(const QString loc)
{
m_location = QString(loc);
}
void Task::setLastModified(const QDateTime last)
{
m_lastModified = QDateTime(last);
}
void Task::setClass(const QString cls)
{
m_class = QString(cls);
}
void Task::setStatus(const QString stat)
{
m_status = QString(stat);
}
QString Task::toString()
{
return QString("UID: %3\n\tSummary: %1,\n\tDescription: %2\n\tLocation: %4\n\tLast Modified: %5\n\tStatus: %6\n\tClass: %7")
.arg(m_summary).arg(m_description).arg(m_uid).arg(m_location).arg(m_lastModified.toString()).arg(m_status).arg(m_class);
}