jksilva
jksilva

Reputation: 1

google.protobuf.any variable put in to int array in C++

I have a variable called mapData in google.protobuf.Any type. How would I put that mapData information in to an int array in C++.
I am using proto3 syntax.

message A{
  uint32 id;
  google.protobuf.Any mapData ;
}

std::array<uint32,10> data;
uint32 varID = message.id;
data[0] = message.mapData; //get compile error  - cannot convert google.protobuf.Any to std:array<uint32,10, 10> in assignment

Upvotes: 0

Views: 128

Answers (0)

Related Questions