- DocListItem (std::string title, std::string url,
- std::time_t ctime, std::time_t mtime, std::string desc ) {
- this->title = escape_html (title);
- this->url = url;
- this->ctime = ctime;
- this->mtime = mtime;
- this->desc = desc;
+ DocListItem (Document *doc, std::string urlpath) {
+ this->title = doc->get_title ();
+ this->url = urlpath + doc->get_filename() + ".html";
+ this->ctime = doc->get_creation_date ();
+ this->mtime = doc->get_modified_date ();
+ this->desc = doc->get_meta_desc ();