This repository has been archived on 2025-04-11. You can view files and clone it, but cannot push or open issues or pull requests.
dmspine64backup/user.h

102 lines
1.9 KiB
C
Raw Normal View History

2015-09-30 17:10:16 -05:00
#include <fstream>
#include <iostream>
#include <vector>
2015-10-06 12:17:54 -05:00
using namespace std;
2015-09-30 17:10:16 -05:00
2015-10-06 12:17:54 -05:00
class User {
string name;
string password;
string phone_number;
string fax_number;
string postal_address;
vector<string> groups;
vector<string> messages;
bool is_admin;
bool is_logged_in;
public:
User();
User(string n, string pass, string phone, string fax, string postal, bool admin);
string getName();
string getPassword();
string getPhoneNumber();
string getFaxNumber();
string getPostalAddress();
vector<string> getGroups();
vector<string> getMessages();
bool confirmAdmin();
bool checkLogin();
void setName(string new_name);
void setPassword(string new_name);
void setPhone(string new_phone);
void setFax(string new_fax);
void setPostal(string new_postal);
vector<string> getInfo();
};
class Message {
string sender;
string receiver;
string timestamp;
string text;
public:
Message();
Message(string time, string t, string s, string r);
string getSender();
string getReceiver();
string getTimestamp();
string getText();
void changeText(string input);
vector<string> getInfo();
};
class Board {
string name;
string description;
bool lockedForGroup;
string group;
2015-09-30 17:10:16 -05:00
2015-10-06 12:17:54 -05:00
public:
Board();
Board(string n, string d);
Board(string n, string d, bool l, string g);
string getName();
string getDescription();
bool checkIfLocked();
string getGroup();
vector<string> getInfo();
};
class Group {
string name;
string description;
vector<Board> boards;
2015-09-30 17:10:16 -05:00
2015-10-06 12:17:54 -05:00
public:
Group();
Group(string n, string d);
string getName();
string getDescription();
vector<Board> getBoards();
void addBoard(Board input);
vector<string> getInfo();
};
2015-09-30 17:10:16 -05:00
2015-10-06 12:17:54 -05:00
class Article {
string author;
string timestamp;
int length;
2015-09-30 17:10:16 -05:00
2015-10-06 12:17:54 -05:00
public:
Article();
Article(string a, string t, int l);
string getAuthor();
string getTimestamp();
string getLength();
vector<string> getInfo();
};
2015-09-30 17:10:16 -05:00