00001
00002
00003
00004
00005 #ifndef PLAYA_MPISESSION_H
00006 #define PLAYA_MPISESSION_H
00007
00008
00009
00010
00011
00012 #include "PlayaDefs.hpp"
00013 #include <stack>
00014
00015 #ifdef HAVE_MPI
00016 #include "mpi.h"
00017 #endif
00018
00019 namespace Playa
00020 {
00021
00022
00023
00024
00025 class MPISession
00026 {
00027 public:
00028
00029 static void init(int* argc, void*** argv);
00030
00031
00032 static int getRank() {return rank_;}
00033
00034
00035 static int getNProc() {return nProc_;}
00036
00037
00038 static void finalize();
00039
00040
00041
00042 static bool& showStartupMessage() {static bool rtn=false; return rtn;}
00043
00044 private:
00045 static int rank_;
00046 static int nProc_;
00047 };
00048 }
00049
00050 #endif