vtkSMSettingsProxy.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: ParaView
4  Module: vtkSMSettingsProxy.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 =========================================================================*/
65 #ifndef vtkSMSettingsProxy_h
66 #define vtkSMSettingsProxy_h
67 
68 #include "vtkRemotingServerManagerModule.h" //needed for exports
69 #include "vtkSMProxy.h"
70 
72 {
73 public:
74  static vtkSMSettingsProxy* New();
76  void PrintSelf(ostream& os, vtkIndent indent) override;
77 
83 
85 
88  static void ProcessPropertyLinks(vtkSMProxy* proxy);
90 
92 
97  void AddLink(const char* sourceProperty, vtkSMProxy* target, const char* targetProperty,
98  bool unlink_if_modified);
99  void RemoveLink(const char* sourceProperty, vtkSMProxy* target, const char* targetProperty);
101 
106  const char* GetSourcePropertyName(vtkSMProxy* target, const char* targetProperty);
107 
109 
112  void SaveLinksState(vtkPVXMLElement* root);
113  void LoadLinksState(vtkPVXMLElement* root, vtkSMProxyLocator* locator);
115 
117 
120  vtkSetMacro(IsSerializable, bool);
121  vtkGetMacro(IsSerializable, bool);
123 
124 protected:
126  ~vtkSMSettingsProxy() override;
127 
131  void CreateVTKObjects() override;
132 
133  void SetPropertyModifiedFlag(const char* name, int flag) override;
134 
135 private:
136  vtkSMSettingsProxy(const vtkSMSettingsProxy&) = delete;
137  void operator=(const vtkSMSettingsProxy&) = delete;
138 
142  void VTKObjectModified();
143 
144  void AutoBreakMapPropertyLink(vtkObject*, unsigned long, void*);
145 
146  unsigned long VTKObjectObserverId = 0;
147  bool IsSerializable = false;
148 
149  class vtkInternals;
150  vtkInternals* Internals;
151 };
152 
153 #endif
void PrintSelf(ostream &os, vtkIndent indent) override
#define VTKREMOTINGSERVERMANAGER_EXPORT
virtual int ReadXMLAttributes(vtkSMSessionProxyManager *pm, vtkPVXMLElement *element)
Read attributes from an XML element.
virtual void SetPropertyModifiedFlag(const char *name, int flag)
Note on property modified flags: The modified flag of each property associated with a proxy is stored...
proxy subclass responsible for linking settings proxies and settings classes on the VTK side...
The vtkSMSessionProxyManager is esponsible for creating and managing proxies for a given session...
static vtkSMProxy * New()
virtual void CreateVTKObjects()
Given a class name (by setting VTKClassName) and server ids (by setting ServerIDs), this methods instantiates the objects on the server(s)
proxy for a VTK object(s) on a server
Definition: vtkSMProxy.h:152
is used to locate proxies referred to in state xmls while loading state files.
void operator=(const vtkSMProxy &)=delete
vtkSMProxyInternals * Internals
Definition: vtkSMProxy.h:1013
This is used by vtkPVXMLParser to represent an XML document starting at the root element.