I'm trying to talk to a C# program that uses protobuf-net from an iphone using http://code.google.com/p/metasyntactic/wiki/ProtocolBuffers
Unfortunately the .proto file I've been given (generated from the C# source code) includes an a line that protoc is rejecting:
repeated Pair_Guid_List`1 Local = 6;
It appears that this is because the source data is a C# Dictionary, with a Guid key and a class as the value. Is there a way to cope with this better?
The protobuf-net version in use is r278.zip.
(The C# sending and receiving these protobufs all works fine, it's just when we add the iphone into the mix that this becomes an issue.)
UPDATE: all working now thanks to Marc!
The object on the C# side turned out to be:
[ProtoMember(7)]
public Dictionary<Guid, List<Pages>> ReceivedPages { get; set; }
which worked fine using the following in the .proto:
message PagesDict {
required bcl.Guid guid = 1;
repeated Pages Pages = 2;
}
with the message in question containing:
repeated PagesDict ReceivedPages = 7;