00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00047 #ifndef __vtkSMProxyProperty_h
00048 #define __vtkSMProxyProperty_h
00049
00050 #include "vtkSMProperty.h"
00051
00052 class vtkSMProxy;
00053
00054 struct vtkSMProxyPropertyInternals;
00055
00056
00057 class VTK_EXPORT vtkSMProxyProperty : public vtkSMProperty
00058 {
00059 public:
00060 static vtkSMProxyProperty* New();
00061 vtkTypeRevisionMacro(vtkSMProxyProperty, vtkSMProperty);
00062 void PrintSelf(ostream& os, vtkIndent indent);
00063
00065
00066 int AddProxy(vtkSMProxy* proxy);
00067 void RemoveProxy(vtkSMProxy* proxy);
00068 int SetProxy(unsigned int idx, vtkSMProxy* proxy);
00070
00081 int AddProxy(vtkSMProxy* proxy, int modify);
00082
00084 void RemoveProxy(vtkSMProxy* proxy, int modify);
00085
00087
00092 void AddUncheckedProxy(vtkSMProxy* proxy);
00093 void RemoveUncheckedProxy(vtkSMProxy* proxy);
00094 void SetUncheckedProxy(unsigned int idx, vtkSMProxy* proxy);
00096
00098 void RemoveAllUncheckedProxies();
00099
00101 void RemoveAllProxies();
00102
00104 unsigned int GetNumberOfProxies();
00105
00107 unsigned int GetNumberOfUncheckedProxies();
00108
00110 vtkSMProxy* GetProxy(unsigned int idx);
00111
00113 vtkSMProxy* GetUncheckedProxy(unsigned int idx);
00114
00116 virtual void Copy(vtkSMProperty* src);
00117
00119
00123 virtual void DeepCopy(vtkSMProperty* src, const char* exceptionClass,
00124 int proxyPropertyCopyFlag);
00126 protected:
00127 vtkSMProxyProperty();
00128 ~vtkSMProxyProperty();
00129
00130
00132
00138 virtual void AppendCommandToStream(
00139 vtkSMProxy*, vtkClientServerStream* stream, vtkClientServerID objectId );
00140
00142
00144 virtual void UpdateAllInputs();
00145
00147 virtual void SaveState(const char* name, ostream* file, vtkIndent indent);
00148
00149
00150
00151
00152
00153
00154
00156 void AddPreviousProxy(vtkSMProxy* proxy);
00157 void RemoveAllPreviousProxies();
00159
00161 void RemoveConsumers(vtkSMProxy* proxy);
00162
00163
00164 friend class vtkSMProxy;
00165
00166
00167 vtkSMProxyPropertyInternals* PPInternals;
00168
00170
00172 vtkSetStringMacro(CleanCommand);
00173 vtkGetStringMacro(CleanCommand);
00174 char* CleanCommand;
00176
00178
00184 vtkSetStringMacro(RemoveCommand);
00185 vtkGetStringMacro(RemoveCommand);
00186 char* RemoveCommand;
00188
00190
00192 virtual int ReadXMLAttributes(vtkSMProxy* parent,
00193 vtkPVXMLElement* element);
00195
00196 vtkSetMacro(RepeatCommand, int);
00197 vtkGetMacro(RepeatCommand, int);
00198 int RepeatCommand;
00199
00200 void AppendCommandToStreamWithRemoveCommand(
00201 vtkSMProxy* cons, vtkClientServerStream* str, vtkClientServerID objectId );
00202
00203
00204 void AppendProxyToStream(vtkSMProxy* toAppend,
00205 vtkSMProxy* cons, vtkClientServerStream* str, vtkClientServerID objectId, int remove=0 );
00206 private:
00207 vtkSMProxyProperty(const vtkSMProxyProperty&);
00208 void operator=(const vtkSMProxyProperty&);
00209 };
00210
00211 #endif