1 #ifndef VTESTBED_DB_ENTITY_HH 2 #define VTESTBED_DB_ENTITY_HH 6 #include <sqlitex/forward.hh> 7 #include <sqlitex/blob.hh> 16 typedef int64_t id_type;
25 sqlite::blob _filecontent;
29 inline id_type id()
const {
return this->_id; }
30 inline void id(id_type rhs) { this->_id = rhs; }
31 inline bool has_id()
const {
return this->_id != 0; }
32 inline const std::string& name()
const {
return this->_name; }
34 inline void name(
const std::string& rhs) { this->_name = rhs; }
38 return this->_description;
43 this->_description = rhs;
48 return this->_filename;
51 inline const sqlite::blob&
52 file_content()
const {
53 return this->_filecontent;
60 this->_description.clear();
61 this->_filename.clear();
62 this->_filecontent.clear();
77 #endif // vim:filetype=cpp