-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathToDo.h
41 lines (37 loc) · 899 Bytes
/
ToDo.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
#include <iostream>
#include <string.h>
#include "Date.h"
#pragma once
class ToDo
{
private:
int prior;
Date date;
std::string tag;
bool done;
public:
ToDo();
ToDo(const ToDo& todo);
ToDo(int prior, const Date& date, const std::string& tag, bool done);
~ToDo();
//setters
void setPriority ( int nPriority = 0 );
void setDate ( const Date& nDate );
void setTag ( const std::string& tag );
void setDone ( bool nDone = false);
//getters
int getPriority ();
Date& getDate ();
const std::string& getTag ();
bool getDone ();
ToDo* operator=(const ToDo& todo);
bool operator==(const std::string& tag);
};
class ToDoAdapter
{
public:
ToDoAdapter(ToDo& todo);
std::string operator()() const;
private:
std::string represent;
};