vtkSMStateLocator.h
Go to the documentation of this file.
1 // SPDX-FileCopyrightText: Copyright (c) Kitware Inc.
2 // SPDX-License-Identifier: BSD-3-Clause
11 #ifndef vtkSMStateLocator_h
12 #define vtkSMStateLocator_h
13 
14 #include "vtkRemotingServerManagerModule.h" //needed for exports
15 #include "vtkSMMessageMinimal.h" // needed for vtkSMMessage.
16 #include "vtkSMObject.h"
17 #include "vtkWeakPointer.h" // need for observer
18 
19 class vtkSMProxy;
20 class vtkSMSession;
21 class vtkUndoStack;
22 
24 {
25 public:
26  static vtkSMStateLocator* New();
28  void PrintSelf(ostream& os, vtkIndent indent) override;
29 
31 
35  vtkSetObjectMacro(ParentLocator, vtkSMStateLocator);
36  vtkGetObjectMacro(ParentLocator, vtkSMStateLocator);
38 
43  void InitGarbageCollector(vtkSMSession*, vtkUndoStack*);
44 
52  virtual bool FindState(vtkTypeUInt32 globalID, vtkSMMessage* stateToFill, bool useParent = true);
53 
58  virtual void RegisterState(const vtkSMMessage* state);
59 
64  virtual void UnRegisterState(vtkTypeUInt32 globalID, bool force);
65 
70  virtual void UnRegisterAllStates(bool force);
71 
76  virtual bool IsStateLocal(vtkTypeUInt32 globalID);
77 
81  virtual bool IsStateAvailable(vtkTypeUInt32 globalID);
82 
88  virtual void RegisterFullState(vtkSMProxy* proxy);
89 
90 protected:
92  ~vtkSMStateLocator() override;
93 
97 
98 private:
99  vtkSMStateLocator(const vtkSMStateLocator&) = delete;
100  void operator=(const vtkSMStateLocator&) = delete;
101 
102  class vtkInternal;
103  vtkInternal* Internals;
104 };
105 
106 #endif
undo/redo stack.
Definition: vtkUndoStack.h:35
#define VTKREMOTINGSERVERMANAGER_EXPORT
vtkSMSession is the default ParaView session.
Definition: vtkSMSession.h:22
vtkWeakPointer< vtkSMSession > Session
Header class that setup every thing in order to use Protobuf messages in a transparent manner...
superclass for most server manager classes
Definition: vtkSMObject.h:17
static vtkSMObject * New()
proxy for a VTK object(s) on a server
Definition: vtkSMProxy.h:140
vtkWeakPointer< vtkUndoStack > UndoStack
vtkSMStateLocator * ParentLocator
Class used to retrieve a given message state based on its GlobalID.
void PrintSelf(ostream &os, vtkIndent indent) override