Query regarding use of repeated to contain the message of vector.

14 views
Skip to first unread message

rohit nv

unread,
Jun 5, 2020, 5:06:16 AM6/5/20
to grpc.io
Hello All

I am using unary  rpc call to send  & recieve data at client -server .

syntax = "proto3";

import "google/protobuf/empty.proto";

message Dummy {
  string foo = 1;
  repeated int bar = 2;
}

message DummyList {
  Dummy dummy = 1;
}

service DummyService {
  rpc getDummyListWithRepeated(google.protobuf.Empty) returns (DummyList) {}
}

Want to know how can I use the DummyList in a c++ project  to copy the value from a  vector of integer values into bar field of Dummy message.

Would be grateful if someone can share some useful reference links of pseudocode.

Regards,
Rohit
Reply all
Reply to author
Forward
0 new messages