Protocol Buffers - Google's data interchange format (grpc依赖) https://developers.google.com/protocol-buffers/
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

42 lines
755 B

// A series of messages with various kinds of cycles in them.
// +-+---+ +---+
// V | | | |
// A -> B-+-> C -> D<--+
// ^ | |
// +----------+----+
//
// This tests the following cases:
// - B and C are together in multiple cycles
// - B and D are cycles to themselves.
message A {
optional B b = 1;
}
message B {
optional B b = 1;
optional C c = 2;
}
message C {
optional A a = 1;
optional B b = 2;
optional D d = 3;
}
message D {
optional A a = 1;
optional D d = 2;
}
// A proto with a bunch of simple primitives.
message SimplePrimitives {
optional fixed64 a = 1;
optional fixed32 b = 2;
optional double c = 3;
optional float d = 5;
//optional sint64 e = 6;
//optional sint32 f = 7;
}