Rework book server and client.

This commit is contained in:
Chunting Gu
2019-09-06 17:40:46 +08:00
parent f1ad97b227
commit 2a25340ce4
24 changed files with 1120 additions and 301 deletions
+24
View File
@@ -0,0 +1,24 @@
#ifndef BOOK_H_
#define BOOK_H_
#include <iosfwd>
#include <string>
#include "boost/filesystem/path.hpp"
struct Book {
std::string id;
std::string title;
double price;
std::string photo; // Name only
bool IsNull() const {
return id.empty();
}
};
std::ostream& operator<<(std::ostream& os, const Book& book);
extern const Book kNullBook;
#endif // BOOK_H_