-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdb.proto
More file actions
44 lines (38 loc) · 809 Bytes
/
db.proto
File metadata and controls
44 lines (38 loc) · 809 Bytes
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
syntax = "proto2";
package keystoneDB;
message Column{
enum ColumnType{
COLUMN_INT = 0;
COLUMN_CHAR = 1;
COLUMN_NULL = 3;
COLUMN_FLOAT = 4;
}
optional ColumnType type = 1;
optional int32 integer_num = 2;
optional string str = 3;
optional double float_num = 4;
}
message Row {
repeated Column columns = 1;
}
message TableMetadata {
repeated DBDefinition definitions = 1;
optional uint64 nextId = 2;
optional bool hasPrimary = 3;
}
message DBDefinition{
enum DefinitionType{
INTEGER = 1;
CHAR = 2;
FLOAT = 3;
}
optional DefinitionType type = 1;
optional string name = 2;
optional bool isPrimary = 3;
optional bool isIndex = 4;
optional uint64 charLen = 5;
optional bool nullable = 6;
}
message DBMetadata {
repeated string tables = 1;
}