Re: [protobuf] Is there any possible way bind Protocol Buffer with Hibernate,MyBatis Or JDBC

683 views
Skip to first unread message

Oliver Jowett

unread,
Jun 18, 2012, 2:08:14 PM6/18/12
to Jessen Gan, prot...@googlegroups.com
On Mon, Jun 18, 2012 at 3:07 AM, Jessen Gan <jess...@gmail.com> wrote:
> Recently,I used Protocol Buffer as a middleware to trans data between server
> and mobile_client.Read data from database by hibernate into java
> entities,then add into Protocol Buffer Object property one by one.It's a
> very heavy method.
>
> But I googled many key worlds to find a shortcut to do the this.the result
> is null.

If you have a set of rules that map your Java fields/methods to
protobuf field names, then you could build the message reflectively
via DynamicMessage.Builder, perhaps?

Oliver

Jessen Gan

unread,
Jul 28, 2012, 4:07:11 AM7/28/12
to prot...@googlegroups.com


在 2012年6月19日星期二UTC+8上午2时08分14秒,Oliver写道:
Thanks answer,is there any tools to do this ?? 
Reply all
Reply to author
Forward
0 new messages