syntax = "proto2";

package com.google.common.truth.extensions.proto;

option java_package = "com.google.common.truth.extensions.proto";
option java_multiple_files = true;
option java_api_version = 2;

// For brevity: o_ means 'optional', r_ means 'repeated'

message TestMessage2 {
  enum TestEnum2 {
    DEFAULT = 0;
    ONE = 1;
    TWO = 2;
  }

  optional int32 o_int = 1;
  repeated string r_string = 2;
  optional int64 o_long_defaults_to_42 = 3 [default = 42];
  optional TestEnum2 o_enum = 4;

  optional RequiredStringMessage2 o_required_string_message = 5;
  repeated RequiredStringMessage2 r_required_string_message = 6;
  optional TestMessage2 o_test_message = 7;
  repeated TestMessage2 r_test_message = 8;
  optional SubTestMessage2 o_sub_test_message = 9;
  repeated SubTestMessage2 r_sub_test_message = 10;
}

message RequiredStringMessage2 {
  required string required_string = 1;
}

message SubTestMessage2 {
  optional int32 o_int = 1;
  repeated string r_string = 2;

  optional TestMessage2 o_test_message = 3;
  optional SubSubTestMessage2 o_sub_sub_test_message = 4;
}

message SubSubTestMessage2 {
  optional int32 o_int = 1;
  repeated string r_string = 2;
}
