|
Tpetra Matrix/Vector Services
Version of the Day
|
Abstract base class for objects that can be the source of an Import or Export operation, and that also know how to pack their data to send to the target object. More...
#include <Tpetra_SrcDistObjectWithPack.hpp>

Public Member Functions | |
| virtual void | pack (const Teuchos::ArrayView< const LocalOrdinal > &exportLIDs, Teuchos::Array< Packet > &exports, const Teuchos::ArrayView< size_t > &numPacketsPerLID, size_t &constantNumPackets, Distributor &distor) const =0 |
| Pack the object's data for an Import or Export. More... | |
| virtual | ~SrcDistObjectWithPack () |
| Destructor (declared virtual for memory safety of derived classes). More... | |
Abstract base class for objects that can be the source of an Import or Export operation, and that also know how to pack their data to send to the target object.
If an object implements SrcDistObjectWithPack, then that object acknowledges that it knows how to pack its data as the source object of an Import or Export operation. The target object in general assumes responsibility for packing the source object's data. However, the target object (in its packAndPrepare method) may ask the source object to pack its own data, if the source object implements SrcDistObjectWithPack.
Definition at line 75 of file Tpetra_SrcDistObjectWithPack.hpp.
|
inlinevirtual |
Destructor (declared virtual for memory safety of derived classes).
Definition at line 105 of file Tpetra_SrcDistObjectWithPack.hpp.
|
pure virtual |
Pack the object's data for an Import or Export.
| exportLIDs | [in] List of the entries (as local IDs in the source object) we will be sending to other processes. |
| exports | [out] On exit, the buffer for data to send. |
| numPacketsPerLID | [out] On exit, the implementation of this method must do one of two things: set numPacketsPerLID[i] to contain the number of packets to be exported for exportLIDs[i] and set constantNumPackets to zero, or set constantNumPackets to a nonzero value. If the latter, the implementation need not fill numPacketsPerLID. |
| constantNumPackets | [out] On exit, 0 if numPacketsPerLID has variable contents (different size for each LID). If nonzero, then it is expected that the number of packets per LID is constant, and that constantNumPackets is that value. |
| distor | [in] The Distributor object we are using. |
Implemented in Tpetra::CrsMatrix< Scalar, LocalOrdinal, GlobalOrdinal, Node, LocalMatOps >, Tpetra::CrsMatrix< Scalar, LocalOrdinal, GlobalOrdinal, Node, SpMatOps >, and Tpetra::RowMatrix< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
1.8.11