diff options
Diffstat (limited to 'signature_db.hpp')
-rw-r--r-- | signature_db.hpp | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/signature_db.hpp b/signature_db.hpp index f7259bb..5b8f890 100644 --- a/signature_db.hpp +++ b/signature_db.hpp @@ -21,9 +21,20 @@ class signature_db private: signature_db_priv *p; public: - signature_db(); + //open a signature database + //if dbpath is an empty path (default), the database will reside in RAM + //and will be automatically initialized + //otherwise it opens the database specified by dbpath + //if the database specified by dbpath doesn't exist, it will be created + //and initialized + //if the database file exists but is not a valid signature database, it + //will be immediately closed and any subsequent calls to this signature db + //object will do nothing. The object will be marked invalid. + signature_db(const fs::path &dbpath = fs::path()); ~signature_db(); + bool valid(); + //insert image signature into database //id must be unique void put_signature(size_t id, const fs::path &path, const signature &sig); |