VTK
vtkXMLPDataWriter.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkXMLPDataWriter.h
5 
6  Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
7  All rights reserved.
8  See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
9 
10  This software is distributed WITHOUT ANY WARRANTY; without even
11  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12  PURPOSE. See the above copyright notice for more information.
13 
14 =========================================================================*/
24 #ifndef __vtkXMLPDataWriter_h
25 #define __vtkXMLPDataWriter_h
26 
27 #include "vtkIOXMLModule.h" // For export macro
28 #include "vtkXMLWriter.h"
29 
30 class vtkCallbackCommand;
31 
33 {
34 public:
36  void PrintSelf(ostream& os, vtkIndent indent);
37 
39 
40  vtkSetMacro(NumberOfPieces, int);
41  vtkGetMacro(NumberOfPieces, int);
43 
45 
46  vtkSetMacro(StartPiece, int);
47  vtkGetMacro(StartPiece, int);
48  vtkSetMacro(EndPiece, int);
49  vtkGetMacro(EndPiece, int);
51 
53 
54  vtkSetMacro(GhostLevel, int);
55  vtkGetMacro(GhostLevel, int);
57 
59 
62  virtual void SetWriteSummaryFile(int flag);
63  vtkGetMacro(WriteSummaryFile, int);
64  vtkBooleanMacro(WriteSummaryFile, int);
66 
67 protected:
70 
71  // Override writing method from superclass.
72  virtual int WriteInternal();
73 
74  virtual vtkXMLWriter* CreatePieceWriter(int index)=0;
75 
76  virtual void WritePrimaryElementAttributes(ostream &os, vtkIndent indent);
77  int WriteData();
78  virtual void WritePData(vtkIndent indent);
79  virtual void WritePPieceAttributes(int index);
80 
81  char* CreatePieceFileName(int index, const char* path=0);
82  void SplitFileName();
83  int WritePieces();
84  int WritePiece(int index);
85 
86  // Callback registered with the ProgressObserver.
87  static void ProgressCallbackFunction(vtkObject*, unsigned long, void*,
88  void*);
89  // Progress callback from internal writer.
90  virtual void ProgressCallback(vtkAlgorithm* w);
91 
93  int EndPiece;
98 
99  char* PathName;
103 
104  // The observer to report progress from the internal writer.
106 
107 private:
108  vtkXMLPDataWriter(const vtkXMLPDataWriter&); // Not implemented.
109  void operator=(const vtkXMLPDataWriter&); // Not implemented.
110 };
111 
112 #endif
abstract base class for most VTK objects
Definition: vtkObject.h:61
GLuint index
Definition: vtkgl.h:11983
#define vtkGetMacro(name, type)
Definition: vtkSetGet.h:83
#define vtkTypeMacro(thisClass, superclass)
Definition: vtkSetGet.h:619
virtual int WriteData()
Definition: vtkXMLWriter.h:307
supports function callbacks
Superclass for all sources, filters, and sinks in VTK.
Definition: vtkAlgorithm.h:61
GLubyte GLubyte GLubyte GLubyte w
Definition: vtkgl.h:12054
Superclass for VTK's XML file writers.
Definition: vtkXMLWriter.h:52
a simple class to control print indentation
Definition: vtkIndent.h:38
#define VTKIOXML_EXPORT
Write data in a parallel XML format.
virtual int WriteInternal()
vtkCallbackCommand * ProgressObserver
virtual void WritePrimaryElementAttributes(ostream &os, vtkIndent indent)
void PrintSelf(ostream &os, vtkIndent indent)
GLsizei const GLchar ** path
Definition: vtkgl.h:13835
#define vtkBooleanMacro(name, type)
Definition: vtkSetGet.h:234
#define vtkSetMacro(name, type)
Definition: vtkSetGet.h:69