KaMPIng 0.1.1
Flexible and (near) zero-overhead C++ bindings for MPI
|
A scoped MPI_Datatype that commits the type on construction and frees it on destruction. This is useful for RAII-style management of MPI_Datatype objects. More...
#include <mpi_datatype.hpp>
Public Member Functions | |
ScopedDatatype (MPI_Datatype type=MPI_DATATYPE_NULL) | |
Construct a new scoped MPI_Datatype and commits it. If no type is provided, default to MPI_DATATYPE_NULL and does not commit or free anything. | |
ScopedDatatype (ScopedDatatype const &)=delete | |
Deleted copy constructor. | |
ScopedDatatype & | operator= (ScopedDatatype const &)=delete |
Deleted copy assignment. | |
ScopedDatatype (ScopedDatatype &&other) noexcept | |
Move constructor. | |
ScopedDatatype & | operator= (ScopedDatatype &&other) noexcept |
Move assignment. | |
MPI_Datatype const & | data_type () const |
Get the MPI_Datatype. | |
~ScopedDatatype () | |
Free the MPI_Datatype. | |
A scoped MPI_Datatype that commits the type on construction and frees it on destruction. This is useful for RAII-style management of MPI_Datatype objects.