vtkSMOutputPort.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: ParaView
4  Module: vtkSMOutputPort.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 =========================================================================*/
30 #ifndef vtkSMOutputPort_h
31 #define vtkSMOutputPort_h
32 
33 #include "vtkRemotingServerManagerModule.h" //needed for exports
34 #include "vtkSMProxy.h"
35 #include "vtkSmartPointer.h" // needed for vtkSmartPointer
36 #include "vtkWeakPointer.h" // needed for vtkWeakPointer
37 
38 #include <map> // needed for std::map
39 
40 class vtkCollection;
46 class vtkSMSourceProxy;
47 
49 {
50 public:
51  static vtkSMOutputPort* New();
52  vtkTypeMacro(vtkSMOutputPort, vtkSMProxy);
53  void PrintSelf(ostream& os, vtkIndent indent) override;
54 
61  virtual vtkPVDataInformation* GetDataInformation();
62 
66  vtkPVDataInformation* GetRankDataInformation(int rank);
67 
69 
80  vtkPVDataInformation* GetSubsetDataInformation(
81  const char* selector, const char* assemblyName = nullptr);
83 
88  vtkPVDataInformation* GetSubsetDataInformation(unsigned int compositeIndex);
89 
95  virtual vtkPVTemporalDataInformation* GetTemporalDataInformation();
96 
100  virtual const char* GetDataClassName();
101 
105  virtual vtkPVClassNameInformation* GetClassNameInformation();
106 
110  virtual void InvalidateDataInformation();
111 
113 
116  vtkGetMacro(PortIndex, int);
118 
122  vtkSMSourceProxy* GetSourceProxy();
123 
125 
127  vtkSMSession* GetSession() override;
130 protected:
131  vtkSMOutputPort();
132  ~vtkSMOutputPort() override;
133 
137  virtual void GatherClassNameInformation();
138 
143  virtual void GatherDataInformation();
144 
148  virtual void GatherTemporalDataInformation();
149 
150  void SetSourceProxy(vtkSMSourceProxy* src);
151 
152  // When set to non-nullptr, GetSourceProxy() returns this rather than the real
153  // source-proxy set using SetSourceProxy(). This provides a mechanism for
154  // vtkSMCompoundSourceProxy to take ownership of ports that don't really
155  // belong to it.
156  void SetCompoundSourceProxy(vtkSMCompoundSourceProxy* src);
157 
161  virtual void UpdatePipelineInternal(double time, bool doTime);
162 
163  // The index of the port the output is obtained from.
164  vtkSetMacro(PortIndex, int);
165  int PortIndex;
166 
169 
172 
175 
178 
179  std::map<std::string, std::map<int, vtkSmartPointer<vtkPVDataInformation>>>
181  std::map<int, vtkSmartPointer<vtkPVDataInformation>> RankDataInformations;
182 
183 private:
184  vtkSMOutputPort(const vtkSMOutputPort&) = delete;
185  void operator=(const vtkSMOutputPort&) = delete;
186 
187  friend class vtkSMSourceProxy;
189  void UpdatePipeline();
190 
191  // Update Pipeline with the given timestep request.
192  void UpdatePipeline(double time);
193 };
194 
195 #endif
vtkPVTemporalDataInformation * TemporalDataInformation
bool TemporalDataInformationValid
vtkPVClassNameInformation * ClassNameInformation
provides meta data about a vtkDataObject subclass.
void PrintSelf(ostream &os, vtkIndent indent) override
#define VTKREMOTINGSERVERMANAGER_EXPORT
vtkSMSession is the default ParaView session.
Definition: vtkSMSession.h:35
virtual vtkSMSessionProxyManager * GetSessionProxyManager()
Return the corresponding ProxyManager if any.
fetches vtkDataAssembly from a vtkObject subclass
std::map< int, vtkSmartPointer< vtkPVDataInformation > > RankDataInformations
virtual void UpdatePipeline()
Calls Update() on all sources.
proxy for a VTK source on a server
vtkPVDataInformation * DataInformation
The vtkSMSessionProxyManager is esponsible for creating and managing proxies for a given session...
static vtkSMProxy * New()
a proxy excapsulation a pipeline of proxies.
proxy for a VTK object(s) on a server
Definition: vtkSMProxy.h:152
reference for an output port of a vtkAlgorithm.
std::map< std::string, std::map< int, vtkSmartPointer< vtkPVDataInformation > > > SubsetDataInformations
void operator=(const vtkSMProxy &)=delete
virtual vtkSMSession * GetSession()
Get/Set the session on wihch this object exists.
vtkWeakPointer< vtkSMSourceProxy > SourceProxy
vtkWeakPointer< vtkSMCompoundSourceProxy > CompoundSourceProxy
extends vtkPVDataInformation to gather information across timesteps.