...

Text file src/github.com/grpc-ecosystem/grpc-gateway/runtime/internal/examplepb/example.proto

Documentation: github.com/grpc-ecosystem/grpc-gateway/runtime/internal/examplepb

     1syntax = "proto3";
     2option go_package = "examplepb";
     3
     4import "google/protobuf/timestamp.proto";
     5import "google/protobuf/empty.proto";
     6
     7package grpc.gateway.runtime.internal.examplepb;
     8
     9// SimpleMessage represents a simple message sent to the Echo service.
    10message SimpleMessage {
    11	string id = 1;
    12}
    13
    14message ABitOfEverything {
    15	// Nested is nested type.
    16	message Nested {
    17		// name is nested field.
    18		string name = 1;
    19		uint32 amount = 2;
    20		// DeepEnum is one or zero.
    21		enum DeepEnum {
    22			// FALSE is false.
    23			FALSE = 0;
    24			// TRUE is true.
    25			TRUE = 1;
    26		}
    27
    28		// DeepEnum comment.
    29		DeepEnum ok = 3;
    30	}
    31	Nested single_nested = 25;
    32
    33	string uuid = 1;
    34	repeated Nested nested = 2;
    35	float float_value = 3;
    36	double double_value = 4;
    37	int64 int64_value = 5;
    38	uint64 uint64_value = 6;
    39	int32 int32_value = 7;
    40	fixed64 fixed64_value = 8;
    41	fixed32 fixed32_value = 9;
    42	bool bool_value = 10;
    43	string string_value = 11;
    44	bytes bytes_value = 29;
    45	uint32 uint32_value = 13;
    46	NumericEnum enum_value = 14;
    47	sfixed32 sfixed32_value = 15;
    48	sfixed64 sfixed64_value = 16;
    49	sint32 sint32_value = 17;
    50	sint64 sint64_value = 18;
    51	repeated string repeated_string_value = 19;
    52	oneof oneof_value {
    53		google.protobuf.Empty oneof_empty = 20;
    54		string oneof_string = 21;
    55	}
    56
    57	map<string, NumericEnum> map_value = 22;
    58	map<string, string> mapped_string_value = 23;
    59	map<string, Nested> mapped_nested_value = 24;
    60
    61	string nonConventionalNameValue = 26;
    62
    63	google.protobuf.Timestamp timestamp_value = 27;
    64
    65	// repeated enum value. it is comma-separated in query
    66	repeated NumericEnum repeated_enum_value = 28;
    67
    68	// repeated numeric enum comment (This comment is overridden by the field annotation)
    69	repeated NumericEnum repeated_enum_annotation = 32;
    70
    71	// numeric enum comment (This comment is overridden by the field annotation)
    72	NumericEnum enum_value_annotation = 33;
    73
    74	// repeated string comment (This comment is overridden by the field annotation)
    75	repeated string repeated_string_annotation = 34;
    76
    77	// repeated nested object comment (This comment is overridden by the field annotation)
    78	repeated Nested repeated_nested_annotation = 35;
    79
    80	// nested object comments (This comment is overridden by the field annotation)
    81	Nested nested_annotation = 36;
    82
    83	int64 int64_override_type = 37;
    84}
    85
    86// NumericEnum is one or zero.
    87enum NumericEnum {
    88	// ZERO means 0
    89	ZERO = 0;
    90	// ONE means 1
    91	ONE = 1;
    92}
    93
    94message ResponseBodyOut {
    95	message Response {
    96		string data = 1;
    97	}
    98	Response response = 2;
    99}
   100
   101message RepeatedResponseBodyOut {
   102	message Response {
   103		string data = 1;
   104		enum ResponseType {
   105			// UNKNOWN
   106			UNKNOWN = 0;
   107			// A is 1
   108			A = 1;
   109			// B is 2
   110			B = 2;
   111		}
   112		ResponseType type = 3;
   113	}
   114	repeated Response response = 2;
   115}

View as plain text