aboutsummaryrefslogtreecommitdiff
path: root/common/changelog/model.hxx
diff options
context:
space:
mode:
Diffstat (limited to 'common/changelog/model.hxx')
-rw-r--r--common/changelog/model.hxx47
1 files changed, 47 insertions, 0 deletions
diff --git a/common/changelog/model.hxx b/common/changelog/model.hxx
new file mode 100644
index 0000000..e4c630e
--- /dev/null
+++ b/common/changelog/model.hxx
@@ -0,0 +1,47 @@
+// file : common/changelog/model.hxx
+// copyright : Copyright (c) 2009-2013 Code Synthesis Tools CC
+// license : GNU GPL v2; see accompanying LICENSE file
+
+#ifndef MODEL_HXX
+#define MODEL_HXX
+
+#include <vector>
+
+#pragma db model version(1, 1, true)
+
+#pragma db value
+struct value
+{
+ int x;
+ int y;
+};
+
+struct object1;
+
+#pragma db object
+struct object
+{
+ #pragma db id auto
+ int id;
+
+ #pragma db null default(0) options("DUMMY=1")
+ int num;
+
+ #pragma db index unique member(num, "DESC") method("BTREE") options("DUMMY=1")
+
+ #pragma db index
+ value v; // Multi-column.
+
+ std::vector<int> nums;
+ object1* o1;
+};
+
+#pragma db object
+struct object1
+{
+ #pragma db id
+ value id; // Multi-column.
+ int num;
+};
+
+#endif // MODEL_HXX