blob: 68e854a8d83789ab9e23132de08e3dc8cf468d9b (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
|
// file : common/changelog/model.hxx
// copyright : Copyright (c) 2009-2015 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, open)
#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
|