My requirement is to be able serialize and deserialize a Map<String,
Double> which is map String key and double value pairs.

So when i try doing the following structure

message Entry {
  required string key = 1;
  required float  value = 2;
// Our address book file is just one of these.
message StatsMsg {
  required int32 enc = 1;
  repeated Entry   entry    = 2

The Java class generated gives a list which is inefficient in
accessing keys [O(N)]. I would rather want a map equvivalent to be
generated for the same.

How do i do it.

You received this message because you are subscribed to the Google Groups 
"Protocol Buffers" group.
To post to this group, send email to protobuf@googlegroups.com
To unsubscribe from this group, send email to 
For more options, visit this group at 

Reply via email to