aboutsummaryrefslogtreecommitdiffhomepage
path: root/php/tests/proto/test_descriptors.proto
blob: d42aec7cec4f40ba68821c04506b4801d271c56a (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
syntax = "proto3";

package descriptors;

message TestDescriptorsMessage {
  int32 optional_int32 = 1;
  TestDescriptorsEnum optional_enum = 16;
  Sub optional_message = 17;

  // Repeated
  repeated int32 repeated_int32 = 31;
  repeated Sub repeated_message = 47;

  oneof my_oneof {
    int32 oneof_int32    = 51;
  }

  map<int32, EnumSub> map_int32_enum = 71;

  message Sub {
    int32 a = 1;
    repeated int32 b = 2;
  }

  enum EnumSub {
    ZERO = 0;
    ONE = 1;
  }
}

enum TestDescriptorsEnum {
  ZERO = 0;
  ONE  = 1;
}