[This is preliminary documentation and is subject to change.]
Packs (serializes) data into a byte buffer. This serialized representation can be transmitted via MPI
with the datatype MPI_PACKEDand unpacked with MPI_Unpack(IntPtr, Int32, Int32%, IntPtr, Int32, Int32, Int32). Serialization
in MPI.NET is automatic, so this routine is very rarely used.
Namespace:
MPIAssembly: MPI (in MPI.dll)
Version: 0.6.0.0 (0.6.0.0)
Syntax
| C# |
|---|
public static int MPI_Pack( IntPtr inbuf, int incount, int datatype, IntPtr outbuf, int outsize, ref int position, int comm ) |
| Visual Basic (Declaration) |
|---|
Public Shared Function MPI_Pack ( _ inbuf As IntPtr, _ incount As Integer, _ datatype As Integer, _ outbuf As IntPtr, _ outsize As Integer, _ ByRef position As Integer, _ comm As Integer _ ) As Integer |
| Visual C++ |
|---|
public: static int MPI_Pack( IntPtr inbuf, int incount, int datatype, IntPtr outbuf, int outsize, int% position, int comm ) |
Parameters
- inbuf
- Type: System..::.IntPtr
Pointer to the input buffer, containing incount values with the MPI datatype datatype.
- incount
- Type: System..::.Int32
The number of values in inbuf.
- datatype
- Type: System..::.Int32
The MPI datatype of the values in inbuf.
- outbuf
- Type: System..::.IntPtr
A pointer to the buffer of bytes into which we will be packing the serialized representation of the data in inbuf.
- outsize
- Type: System..::.Int32
The size (in bytes) of outbuf.
- position
- Type:
System..::.Int32
%
A pointer to the position (in bytes) into outbuf where the packed data will be written. This position will be updated to the next available position in the buffer once the serialized data has been written.
- comm
- Type: System..::.Int32
The communicator over which the packed data will be sent.