ParaView
vtkSMWriterFactory.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: ParaView
4  Module: vtkSMWriterFactory.h
5 
6  Copyright (c) Kitware, Inc.
7  All rights reserved.
8  See Copyright.txt or http://www.paraview.org/HTML/Copyright.html 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 =========================================================================*/
32 #ifndef vtkSMWriterFactory_h
33 #define vtkSMWriterFactory_h
34 
35 #include "vtkPVServerManagerCoreModule.h" //needed for exports
36 #include "vtkSMObject.h"
37 
38 class vtkPVXMLElement;
39 class vtkSMProxy;
40 class vtkSMSession;
42 class vtkSMSourceProxy;
43 class vtkStringList;
44 
45 class VTKPVSERVERMANAGERCORE_EXPORT vtkSMWriterFactory : public vtkSMObject
46 {
47 public:
48  static vtkSMWriterFactory* New();
50  void PrintSelf(ostream& os, vtkIndent indent);
51 
55  void Initialize();
56 
60  void RegisterPrototype(const char* xmlgroup, const char* xmlname);
61 
65  bool CanWrite(vtkSMSourceProxy*, unsigned int outputport);
66 
75  vtkSMProxy* CreateWriter(const char* filename, vtkSMSourceProxy*, unsigned int outputport);
76  vtkSMProxy* CreateWriter(const char* filename, vtkSMSourceProxy* pxy)
77  {
78  return this->CreateWriter(filename, pxy, 0);
79  }
80 
88  const char* GetSupportedFileTypes(vtkSMSourceProxy* source, unsigned int outputport);
90  {
91  return this->GetSupportedFileTypes(source, 0);
92  }
93 
94  // Returns the number of registered prototypes.
95  unsigned int GetNumberOfRegisteredPrototypes();
96 
101  void UpdateAvailableWriters();
102 
104 
108  void AddGroup(const char* groupName);
109  void RemoveGroup(const char* groupName);
110  void GetGroups(vtkStringList* groups);
112 
123  static void AddWriterToWhitelist(const char* writerxmlgroup, const char* writerxmlname);
124 
125 protected:
128 
129 private:
130  vtkSMWriterFactory(const vtkSMWriterFactory&) VTK_DELETE_FUNCTION;
131  void operator=(const vtkSMWriterFactory&) VTK_DELETE_FUNCTION;
132 
133  class vtkInternals;
134  vtkInternals* Internals;
135 };
136 
137 #endif
void PrintSelf(ostream &os, vtkIndent indent)
vtkSMSession is the default ParaView session.
Definition: vtkSMSession.h:35
const char * GetSupportedFileTypes(vtkSMSourceProxy *source)
vtkSMProxy * CreateWriter(const char *filename, vtkSMSourceProxy *pxy)
superclass for most server manager classes
Definition: vtkSMObject.h:31
proxy for a VTK source on a server
The vtkSMSessionProxyManager is esponsible for creating and managing proxies for a given session...
is a factory or creating a writer based on the data type information from the output port...
static vtkSMObject * New()
proxy for a VTK object(s) on a server
Definition: vtkSMProxy.h:152
This is used by vtkPVXMLParser to represent an XML document starting at the root element.