Newsgroups: comp.parallel.pvm
From: Eric George <georgee@nichols.com>
Subject: Re: Structs in C, Classes in C++
Organization: Nichols Research
Date: Mon, 16 Mar 1998 15:45:53 -0700
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Message-ID: <350DABA1.62F33F79@nichols.com>

Why not just overload the packing and unpacking routines to take your
class members as arguments?  Then you just take it apart/put it back
together inside the function, but never have to see it again.  Of course
this only works for C++.

As far as the other suggestion, this would be a shallow copy I believe.
If you have dynamically allocated memory within your class it won't copy
right as it will only copy the pointer to the data, not the data itself.
Eric

Raymond Fares Jr wrote:

>     Is there anyway to use class or structs with PVM? I would like to
> send the whole struct or class from one processor to another. Is this
> possible or do I have to take each member of the struct, pack it, send
> it, recv, unpack and put back together.
>
> Ray




