syntax = "proto3";
import "db.proto";
option java_multiple_files = true;
option java_package = "com.ub";
option objc_class_prefix = "TEST";
message NewRecord {
DbRecord db=1;
}
message UserInfo{
message UserBasicInfo{
string username =1;
string password =2;
}
UserBasicInfo userBasicInfo =1;
int32 age =2;
double salary =3;
}
message StudentInfo {
UserInfo.UserBasicInfo userBasicInfo =1;
int32 studentId =2;
}
文章来源地址https://www.toymoban.com/news/detail-415391.html
文章来源:https://www.toymoban.com/news/detail-415391.html
到了这里,关于protobuf: 在一条Message中使用另一条Message内部定义的Message的类型的文章就介绍完了。如果您还想了解更多内容,请在右上角搜索TOY模板网以前的文章或继续浏览下面的相关文章,希望大家以后多多支持TOY模板网!