version 0.3.0
[fms.git] / include / threadwrapper / noncopyable.h
diff --git a/include/threadwrapper/noncopyable.h b/include/threadwrapper/noncopyable.h
new file mode 100644 (file)
index 0000000..2f11cf4
--- /dev/null
@@ -0,0 +1,16 @@
+#ifndef _noncopyable_\r
+#define _noncopyable_\r
+\r
+class NonCopyable\r
+{\r
+protected:\r
+       NonCopyable()                   {}\r
+       virtual ~NonCopyable()  {}\r
+\r
+private:\r
+       // restrict copy and assignment\r
+       NonCopyable(const NonCopyable &rhs);\r
+       const NonCopyable &operator=(const NonCopyable &rhs);\r
+};\r
+\r
+#endif // _noncopyable_\r