summaryrefslogtreecommitdiff
path: root/project2/uuid/uuid.h
diff options
context:
space:
mode:
Diffstat (limited to 'project2/uuid/uuid.h')
-rw-r--r--project2/uuid/uuid.h31
1 files changed, 31 insertions, 0 deletions
diff --git a/project2/uuid/uuid.h b/project2/uuid/uuid.h
new file mode 100644
index 0000000..4c60ae5
--- /dev/null
+++ b/project2/uuid/uuid.h
@@ -0,0 +1,31 @@
+#ifndef UUID_H
+#define UUID_H
+
+#include <iostream>
+
+#ifndef uuid_impl
+class uuid_impl;
+#endif
+
+class UUID {
+ public:
+ UUID();
+ ~UUID();
+ UUID(const UUID &);
+ UUID(const std::string &);
+
+ static UUID generate_random();
+
+ UUID & operator=(const UUID & other);
+ UUID & operator=(const std::string &);
+
+ bool operator!=(const UUID & other) const;
+ bool is_nil() const;
+
+ std::string str() const;
+
+ private:
+ uuid_impl * _uuid;
+};
+
+#endif