fpmas 1.6
Public Member Functions | List of all members
fpmas::api::communication::TypedMpi< T > Class Template Referenceabstract

#include <communication.h>

Inheritance diagram for fpmas::api::communication::TypedMpi< T >:
Inheritance graph
[legend]

Public Member Functions

virtual std::unordered_map< int, std::vector< T > > migrate (std::unordered_map< int, std::vector< T > > export_map)=0
 
virtual std::unordered_map< int, T > allToAll (std::unordered_map< int, T > export_map)=0
 
virtual std::vector< T > gather (const T &data, int root)=0
 
virtual std::vector< T > allGather (const T &data)=0
 
virtual T bcast (const T &data, int root)=0
 
virtual void send (const T &data, int destination, int tag)=0
 
virtual void Isend (const T &data, int destination, int tag, Request &req)=0
 
virtual void Issend (const T &data, int destination, int tag, Request &req)=0
 
virtual void probe (int source, int tag, Status &status)=0
 
virtual bool Iprobe (int source, int tag, Status &status)=0
 
virtual T recv (int source, int tag, Status &status=Status::IGNORE)=0
 

Detailed Description

template<typename T>
class fpmas::api::communication::TypedMpi< T >

A conveniently templated MPI wrapper to handle any type of data.

Provides an intuitive API to send / receive objects of type T through MPI, without having to manually serialize / unserialize data and specify send / receive buffers.

Of course, serialization / unserialization rules must still be specified at the implementation level.

For example, implementations might be based on a JSON or XML serialization of T, on custom MPI Datatypes, or on any other custom protocol.

Member Function Documentation

◆ migrate()

template<typename T >
virtual std::unordered_map< int, std::vector< T > > fpmas::api::communication::TypedMpi< T >::migrate ( std::unordered_map< int, std::vector< T > >  export_map)
pure virtual

◆ allToAll()

template<typename T >
virtual std::unordered_map< int, T > fpmas::api::communication::TypedMpi< T >::allToAll ( std::unordered_map< int, T >  export_map)
pure virtual

◆ gather()

template<typename T >
virtual std::vector< T > fpmas::api::communication::TypedMpi< T >::gather ( const T &  data,
int  root 
)
pure virtual

◆ allGather()

template<typename T >
virtual std::vector< T > fpmas::api::communication::TypedMpi< T >::allGather ( const T &  data)
pure virtual

◆ bcast()

template<typename T >
virtual T fpmas::api::communication::TypedMpi< T >::bcast ( const T &  data,
int  root 
)
pure virtual

◆ send()

template<typename T >
virtual void fpmas::api::communication::TypedMpi< T >::send ( const T &  data,
int  destination,
int  tag 
)
pure virtual

◆ Isend()

template<typename T >
virtual void fpmas::api::communication::TypedMpi< T >::Isend ( const T &  data,
int  destination,
int  tag,
Request req 
)
pure virtual

◆ Issend()

template<typename T >
virtual void fpmas::api::communication::TypedMpi< T >::Issend ( const T &  data,
int  destination,
int  tag,
Request req 
)
pure virtual

◆ probe()

template<typename T >
virtual void fpmas::api::communication::TypedMpi< T >::probe ( int  source,
int  tag,
Status status 
)
pure virtual

◆ Iprobe()

template<typename T >
virtual bool fpmas::api::communication::TypedMpi< T >::Iprobe ( int  source,
int  tag,
Status status 
)
pure virtual

◆ recv()

template<typename T >
virtual T fpmas::api::communication::TypedMpi< T >::recv ( int  source,
int  tag,
Status status = Status::IGNORE 
)
pure virtual

The documentation for this class was generated from the following file: