-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathcompare_test.proto
68 lines (56 loc) · 1.21 KB
/
compare_test.proto
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
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
// Test messages used in compare_test.py.
syntax = "proto2";
package compare_test;
option cc_enable_arenas = true;
enum Enum {
A = 0;
B = 1;
C = 2;
}
message Small {
repeated string strings = 1;
}
message Medium {
repeated int32 int32s = 1;
repeated Small smalls = 2;
repeated group GroupA = 3 {
repeated group GroupB = 4 {
required string strings = 5;
}
}
repeated float floats = 6;
}
message Large {
optional string string_ = 1;
optional int64 int64_ = 2;
optional float float_ = 3;
optional bool bool_ = 4;
optional Enum enum_ = 5;
repeated int64 int64s = 6;
optional Medium medium = 7;
optional Small small = 8;
optional double double_ = 9;
optional WithMap with_map = 10;
}
message Labeled {
required int32 required = 1;
optional int32 optional = 2;
}
message WithMap {
map<int32, Small> value_message = 1;
map<string, string> value_string = 2;
}
message Floats {
optional float float_ = 1;
optional double double_ = 2;
}
message RepeatedFloats {
repeated float float_ = 1 [packed = true];
repeated double double_ = 2 [packed = true];
}
message NestedFloats {
optional Floats floats = 1;
}
message MapFloats {
map<int64, Floats> int_to_floats = 1;
}