Strange. It looks like there is a bug in the type checker for booleans --
it will accept any integer. However, this doesn't explain the encoding
error. Looking at the code, I can't see how this could happen; any non-zero
integer value should result in 1 being written to the wire. The problem
You can use the type's descriptor to inspect the fields it contains and what
all their types are. MyType.DESCRIPTOR is the descriptor for MyType. Once
you've figured out what field you want to read/write, use getattr() /
setattr().
Note that the C++ and Java interfaces for this are somewhat
You should probably contact the authors of protobuf-java-format; I'm not
sure if they pay attention to this list.
Base64 is the best way to encode arbitrary (non-text) data as text.
However, it's really up to the JSON converter code you are using to decide
what format to use. As far as I know,
The dirty little secret of std::wstring is that it does not actually deal
with non-ASCII characters on all platforms. On some platforms wchar_t is
8-bit just like char! You should avoid using wstring and wchar_t for this
reason; define your own types that are exactly what you need.
For protocol
Hi,
I have a protocol buffer object like:
message PBPerson
{
optional string lastName = 1;
optional string firstName = 2;
}
I also have another java object
class JavaPerson
{
private String lastName;
private String firstName;
// setter and getter
}
I want to convert from PBPerson to
Hello,
I originally was using JAX-WS to communicate between client and
server. This
works well when my client is C# and server is Java based service.
I have been asked to speed up the performance using Protocol
Buffers to do
binary serialization instead of text-based serialization.
I'd say use UTF-8 for all strings and you are good to go.
--
You received this message because you are subscribed to the Google Groups
Protocol Buffers group.
To post to this group, send email to proto...@googlegroups.com.
To unsubscribe from this group, send email to
I am using the protobuf-c extension out there.
Getting the following errors:
gcc tut.c tut.pb-c.c -o tut -lprotobuf-c -lprotobuf -lpthread
/tmp/ccBHwTBl.o: In function `main':
tut.c:(.text+0xab): undefined reference to
`a_message__get_packed_size'
tut.c:(.text+0xcc): undefined reference to
Protocol buffers itself has no built-in RPC implementation. You have to
find an RPC implementation that supports whatever languages you are
interested in, or write your own. It's not too hard to write a simple RPC
implementation given protocol buffers as a base. Sending protobufs over
HTTP is a
I don't know of any existing tools for this. You could write code that does
this via reflection (protobuf reflection on the protobuf object, and basic
java reflection on the POJO). Or, you could write a protoc plugin which
generates the code you need, though that will be a lot more complicated.
On Tue, Dec 28, 2010 at 15:14, Kenton Varda ken...@google.com wrote:
Protocol buffers itself has no built-in RPC implementation. You have to
find an RPC implementation that supports whatever languages you are
interested in, or write your own. It's not too hard to write a simple RPC
11 matches
Mail list logo