Re: [protobuf] Re: c++: Print contents of a serialized file using its descriptor file

2010-04-05 Thread Jason Hsueh
On Fri, Apr 2, 2010 at 7:03 PM, Navin wrote: > Yay It works. Thanks a lot. I will post the complete solution for > the AddressBook example, in case someone else faces the same issues as > me. > > My only other question was , I have many different .proto files and > hence I would have multipl

[protobuf] Re: c++: Print contents of a serialized file using its descriptor file

2010-04-02 Thread Navin
Yay It works. Thanks a lot. I will post the complete solution for the AddressBook example, in case someone else faces the same issues as me. My only other question was , I have many different .proto files and hence I would have multiple descriptor files for them (wait is that true. I believe

[protobuf] Re: c++: Print contents of a serialized file using its descriptor file

2010-04-02 Thread Navin
Yay It works. Thanks a lot. I will post the complete solution for the AddressBook example, in case someone else faces the same issues as me. My only other question was , I have many different .proto files and hence I would have multiple descriptor files for them (wait is that true. I believe

Re: [protobuf] Re: c++: Print contents of a serialized file using its descriptor file

2010-04-02 Thread Jason Hsueh
On Fri, Apr 2, 2010 at 6:20 PM, Navin wrote: > I went on a tangent with the use of TextFormat::Parse. I somehow > thought that would help me read the data, but you have clarified, that > would not work. > > So I think we are back to what you originally outlined. I believe i do > NEED the descript

[protobuf] Re: c++: Print contents of a serialized file using its descriptor file

2010-04-02 Thread Navin
I went on a tangent with the use of TextFormat::Parse. I somehow thought that would help me read the data, but you have clarified, that would not work. So I think we are back to what you originally outlined. I believe i do NEED the descriptor files. Correct ? 1. //Open the descriptor file that I

Re: [protobuf] Re: c++: Print contents of a serialized file using its descriptor file

2010-04-02 Thread Jason Hsueh
On Fri, Apr 2, 2010 at 2:40 PM, Navin wrote: > I believe I get the piece about constructing a message for a specific > type given a descriptor file. > > About your last statement: > "If person.pb contains the serialized (binary) data for your proto, > you > should be using one of the Message::Par

[protobuf] Re: c++: Print contents of a serialized file using its descriptor file

2010-04-02 Thread Navin
I believe I get the piece about constructing a message for a specific type given a descriptor file. About your last statement: "If person.pb contains the serialized (binary) data for your proto, you should be using one of the Message::ParseFrom* routines. " My understanding was I needed a "Perso