VTK
|
00001 /*========================================================================= 00002 00003 Program: Visualization Toolkit 00004 Module: vtkPOpenFOAMReader.h 00005 00006 Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen 00007 All rights reserved. 00008 See Copyright.txt or http://www.kitware.com/Copyright.htm for details. 00009 00010 This software is distributed WITHOUT ANY WARRANTY; without even 00011 the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR 00012 PURPOSE. See the above copyright notice for more information. 00013 00014 =========================================================================*/ 00032 #ifndef __vtkPOpenFOAMReader_h 00033 #define __vtkPOpenFOAMReader_h 00034 00035 #include "vtkIOParallelModule.h" // For export macro 00036 #include "vtkOpenFOAMReader.h" 00037 00038 class vtkDataArraySelection; 00039 class vtkMultiProcessController; 00040 00041 class VTKIOPARALLEL_EXPORT vtkPOpenFOAMReader : public vtkOpenFOAMReader 00042 { 00043 public: 00044 //BTX 00045 enum caseType { DECOMPOSED_CASE = 0, RECONSTRUCTED_CASE = 1 }; 00046 //ETX 00047 static vtkPOpenFOAMReader *New(); 00048 vtkTypeMacro(vtkPOpenFOAMReader, vtkOpenFOAMReader); 00049 00050 void PrintSelf(ostream &os, vtkIndent indent); 00051 00053 00054 void SetCaseType(const int t); 00055 vtkGetMacro(CaseType, caseType); 00057 00058 00059 virtual void SetController(vtkMultiProcessController *); 00060 vtkGetObjectMacro(Controller, vtkMultiProcessController); 00062 00063 protected: 00064 vtkPOpenFOAMReader(); 00065 ~vtkPOpenFOAMReader(); 00066 00067 int RequestInformation(vtkInformation *, vtkInformationVector **, 00068 vtkInformationVector *); 00069 int RequestData(vtkInformation *, vtkInformationVector **, 00070 vtkInformationVector *); 00071 00072 private: 00073 vtkMultiProcessController *Controller; 00074 caseType CaseType; 00075 unsigned long MTimeOld; 00076 int MaximumNumberOfPieces; 00077 int NumProcesses; 00078 int ProcessId; 00079 00080 vtkPOpenFOAMReader(const vtkPOpenFOAMReader &); // Not implemented. 00081 void operator=(const vtkPOpenFOAMReader &); // Not implemented. 00082 00083 void GatherMetaData(); 00084 void BroadcastStatus(int &); 00085 void Broadcast(vtkStringArray *); 00086 void AllGather(vtkStringArray *); 00087 void AllGather(vtkDataArraySelection *); 00088 }; 00089 00090 #endif