Thanks man... It worked great! I guess I should read the documentation a little more xP.
On Monday, March 26, 2012 9:49:17 PM UTC-3, Evan Jones wrote: > > On Mar 25, 2012, at 18:09 , Galileo Sanchez wrote: > > else > > if (Should I write the size as a raw bit string?) > > then How do I do that? > > > You need to use something like the following. Not 100% sure it works but > it should be close? Hope this helps, > > Evan > > > # Output a message to be read with Java's parseDelimitedFrom > import google.protobuf.internal.encoder as encoder > out = message.SerializeToString() > out = encoder._VarintBytes(len(out)) + out > > > # Read a message from Java's writeDelimitedTo: > import google.protobuf.internal.decoder as decoder > > # Read length > (size, position) = decoder._DecodeVarint(buffer, 0) > # Read the message > message_object.ParseFromString(buffer[position:position+size]) > > > -- > http://evanjones.ca/ > > -- You received this message because you are subscribed to the Google Groups "Protocol Buffers" group. To view this discussion on the web visit https://groups.google.com/d/msg/protobuf/-/GDPoYpNMZl4J. To post to this group, send email to firstname.lastname@example.org. To unsubscribe from this group, send email to protobuf+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/protobuf?hl=en.