qpid-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Andy Goldstein <andy.goldst...@redhat.com>
Subject Re: Try to send a user-defined struct using C++ QPID
Date Thu, 18 Oct 2012 19:38:52 GMT
Hi Joe,

You have a couple of tried & true options.  You could manually copy the data from the
struct into a Variant::Map and encode that into a Message.  You could use a library such as
Google Protocol Buffers to both store the data in memory (i.e. instead of using a struct you'd
use a protobuf generated class) and for transmission across the wire (since it serializes
to/from a string).

Hope this helps,
Andy

On Oct 18, 2012, at 3:33 PM, Joe Ly wrote:

> Hi,
> 
> Anyone knows how I could send a C/C++ user-defined struct that encodes into qpid messages?
> 
> For example, my struct is defined as
> 
> struct a {
>      int j;
>      float k;
>      float r[29];
> } a;
> 
> 
> Thanks,
> 
> 
> Joe Ly
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@qpid.apache.org
> For additional commands, e-mail: users-help@qpid.apache.org
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@qpid.apache.org
For additional commands, e-mail: users-help@qpid.apache.org


Mime
View raw message