diff options
| author | manzerbredes <loic.guegan_secondary@yahoo.fr> | 2015-03-13 15:07:21 +0400 |
|---|---|---|
| committer | manzerbredes <loic.guegan_secondary@yahoo.fr> | 2015-03-13 15:07:21 +0400 |
| commit | 802410f7a3bdf2db3823f96e122bf1db45bf6a85 (patch) | |
| tree | b761182cd6a6cf47e75b168614b414fd1b5e089e /ParserClass/FileManContainer | |
| parent | 34b47f8e08eff519f6c8372f2e4ce5b24267614c (diff) | |
| parent | c113e7b5f46a3434f017de3f2c9f83a002b246f1 (diff) | |
Merge branch 'PARSER'
Diffstat (limited to 'ParserClass/FileManContainer')
| -rw-r--r-- | ParserClass/FileManContainer/FileManContainer.cpp | 25 | ||||
| -rw-r--r-- | ParserClass/FileManContainer/FileManContainer.hpp | 46 | ||||
| -rw-r--r-- | ParserClass/FileManContainer/Website.cpp | 56 | ||||
| -rw-r--r-- | ParserClass/FileManContainer/Website.hpp | 78 |
4 files changed, 205 insertions, 0 deletions
diff --git a/ParserClass/FileManContainer/FileManContainer.cpp b/ParserClass/FileManContainer/FileManContainer.cpp new file mode 100644 index 0000000..7f04be4 --- /dev/null +++ b/ParserClass/FileManContainer/FileManContainer.cpp @@ -0,0 +1,25 @@ +/** + * @file FileManContainer.cpp + * @brief FileManContainer class definitions + * @author manzerbredes + * @date 11 Mars 2015 + * + * Contain all implementation of FileManContainer class. + * + */ + + +#include "FileManContainer.hpp" + +FileManContainer::FileManContainer(){ +} + + + +void FileManContainer::addWebsite(Website website){ + this->websites.push_back(website); +} + +std::vector<Website> FileManContainer::getWebsites(){ + return this->websites; +} diff --git a/ParserClass/FileManContainer/FileManContainer.hpp b/ParserClass/FileManContainer/FileManContainer.hpp new file mode 100644 index 0000000..d5be276 --- /dev/null +++ b/ParserClass/FileManContainer/FileManContainer.hpp @@ -0,0 +1,46 @@ +/** + * @file FileManContainer.hpp + * @brief FileManContainer class definitions + * @author manzerbredes + * @date 11 Mars 2015 + * + * Contain all definitions of FileManContainer class. + * + */ + +#ifndef __FileManContainer__ +#define __FileManContainer__ + +//----- std ----- + +#include <string> +#include <vector> + +//----- class ----- +#include "Website.hpp" + + +/** + * @class Website Website.hpp "/ParserClass/FileManContainer/Website.hpp" + * @brief Class for manager all FileMan container (websites etc...) + * @author manzerbredes + * + * + * + */ + +class FileManContainer{ + + public: + FileManContainer(); + + void addWebsite(Website website); + std::vector<Website> getWebsites(); + + private: + + std::vector<Website> websites; +}; + + +#endif diff --git a/ParserClass/FileManContainer/Website.cpp b/ParserClass/FileManContainer/Website.cpp new file mode 100644 index 0000000..d54e28a --- /dev/null +++ b/ParserClass/FileManContainer/Website.cpp @@ -0,0 +1,56 @@ +/** + * @file Website.cpp + * @brief Website class definitions + * @author manzerbredes + * @date 11 Mars 2015 + * + * Contain all implementations of Website class. + * + */ + + +#include "Website.hpp" + + +Website::Website(){ + +} + + + + + +std::string Website::getTitle(){ + return this->title; +} +std::string Website::getUrl(){ + return this->url; +} +std::string Website::getUsername(){ + return this->username; +} +std::string Website::getPassword(){ + return this->password; +} +std::string Website::getDescription(){ + return this->description; +} + + + + +void Website::setTitle(std::string title){ + this->title = title; +} +void Website::setUrl(std::string url){ + this->url = url; +} +void Website::setUsername(std::string username){ + this->username = username; +} +void Website::setPassword(std::string password){ + this->password = password; +} +void Website::setDescription(std::string description){ + this->description = description; +} diff --git a/ParserClass/FileManContainer/Website.hpp b/ParserClass/FileManContainer/Website.hpp new file mode 100644 index 0000000..c370f3b --- /dev/null +++ b/ParserClass/FileManContainer/Website.hpp @@ -0,0 +1,78 @@ +/** + * @file Website.hpp + * @brief Website class definitions + * @author manzerbredes + * @date 11 Mars 2015 + * + * Contain all definitions of Website class. + * + */ + +#ifndef __WEBSITE__ +#define __WEBSITE__ + +#include <string> + + +/** + * @class FileManIOFile FileManIOFile.hpp "/CryptClass/FileManIOFile.hpp" + * @brief Class for quick open and close encrypted file. + * @author manzerbredes + * + * -----File organisation----- + * + * 16 first bytes : md5 of decrypted file + * rest of the file : data encrypted (ASE for now) + * + */ + +#include <string> +#include "AbstractIDManager.hpp" + +/** + * @class Website Website.hpp "/ParserClass/FileManContainer/Website.hpp" + * @brief Class for quick open and close encrypted file. + * @author manzerbredes + * + * Container for website data. + * + */ +class Website : public AbstractIDManager { + + + public: + + Website(); + + /** + * @brief Containner getters. + */ + + std::string getTitle(); + std::string getUrl(); + std::string getUsername(); + std::string getPassword(); + std::string getDescription(); + + + /** + * @brief Containner setters. + */ + void setTitle(std::string title); + void setUrl(std::string url); + void setUsername(std::string username); + void setPassword(std::string password); + void setDescription(std::string description); + + + private: + + std::string title; ///< Title of the website + std::string url; ///< Url of the website + std::string username; ///< username of the account + std::string password; ///< password of the account + std::string description; ///< Description of the website +}; + + +#endif |
