syntax = "proto3";

package test3;

enum OuterEnum {
  UNKNOWN = 0;
  FOO3 = 1;
  BAR3 = 2;
}

message OuterMessage3 {
  string a_string = 1;
}

message SimpleProto3 {
  enum InnerEnum {
    INNER1 = 0;
    INNER2 = 1;
  }

  string a_string = 1;
  repeated string a_repeated_string = 2;
  OuterEnum a_outer_enum = 3;
  OuterMessage3 outer_message = 4;
  InnerEnum inner_enum = 15;

  oneof a_oneof {
      string a_oneof_1 = 5;
      string a_oneof_2 = 6;
      OuterMessage3 outer_message_in_oneof = 12;
      OuterEnum outer_enum_in_oneof = 13;
      InnerEnum inner_enum_in_oneof = 14;
  }

  oneof b_oneof {
      string b_oneof_1 = 7;
      string b_oneof_2 = 8;
  }

  OuterMessage3 bool = 9;

  // Test having fieldname match messagename
  OuterEnum OuterEnum = 10;
  OuterMessage3 OuterMessage3 = 11;

  // Test generation of map
  map<int32, string> map_scalar = 16;
  map<int32, OuterMessage3> map_message = 17;

  optional string an_optional_string = 18;
}
