Parallel/vtkMPIGroup.h
Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00046 #ifndef __vtkMPIGroup_h
00047 #define __vtkMPIGroup_h
00048
00049 #include "vtkObject.h"
00050
00051 class vtkMPIController;
00052 class vtkMPICommunicator;
00053
00054 class VTK_PARALLEL_EXPORT vtkMPIGroup : public vtkObject
00055 {
00056
00057 public:
00058
00059 vtkTypeRevisionMacro( vtkMPIGroup,vtkObject);
00060
00063 static vtkMPIGroup* New();
00064
00065 virtual void PrintSelf(ostream& os, vtkIndent indent);
00066
00069 void Initialize(vtkMPIController* controller);
00070
00074 int AddProcessId(int processId);
00075
00078 void RemoveProcessId(int processId);
00079
00082 int FindProcessId(int processId);
00083
00086 int GetProcessId(int pos);
00087
00090 void CopyProcessIdsFrom(vtkMPIGroup* group);
00091
00093
00094 int GetNumberOfProcessIds()
00095 {
00096 return this->CurrentPosition;
00097 }
00099
00100
00101
00102 friend class vtkMPICommunicator;
00103
00104
00105
00106 protected:
00107
00110 void CopyFrom(vtkMPIGroup* group);
00111
00113 void Initialize(int numProcIds);
00114
00115 int* ProcessIds;
00116 int MaximumNumberOfProcessIds;
00117 int Initialized;
00118 int CurrentPosition;
00119
00120 vtkMPIGroup();
00121 ~vtkMPIGroup();
00122
00123 private:
00124 vtkMPIGroup(const vtkMPIGroup&);
00125 void operator=(const vtkMPIGroup&);
00126 };
00127
00128 #endif
00129
00130
00131
00132