VTK  9.7.1
vtkStandaloneSession.h
Go to the documentation of this file.
1 // SPDX-FileCopyrightText: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
2 // SPDX-License-Identifier: BSD-3-Clause
18 #ifndef vtkStandaloneSession_h
19 #define vtkStandaloneSession_h
20 
21 #include "vtkType.h" // for vtkTypeUInt32
22 #include "vtkWebAssemblySessionModule.h" // for no export macro
23 
24 #include <emscripten/val.h> // for emscripten::val
25 
26 VTK_ABI_NAMESPACE_BEGIN
27 
28 typedef struct vtkSessionImpl* vtkSession;
29 class VTKWEBASSEMBLYSESSION_EXPORT vtkStandaloneSession
30 {
31 public:
34 
38  vtkTypeUInt32 Create(const std::string& className);
39 
43  bool Destroy(vtkTypeUInt32 object);
44 
48  bool Set(vtkTypeUInt32 object, emscripten::val properties);
49 
53  emscripten::val Get(vtkTypeUInt32 object);
54 
59  emscripten::val Invoke(vtkTypeUInt32 object, const std::string& methodName, emscripten::val args);
60 
64  unsigned long Observe(
65  vtkTypeUInt32 object, const std::string& eventName, emscripten::val jsFunction);
66 
70  bool UnObserve(vtkTypeUInt32 object, unsigned long tag);
71 
75  bool UnObserveAll(vtkTypeUInt32 object);
76 
80  void UnObserveAllObjects();
81 
86  std::size_t GetTotalBlobMemoryUsage();
87 
92  std::size_t GetTotalVTKDataObjectMemoryUsage();
93 
99  std::string PrintObjectToString(vtkTypeUInt32 object);
100 
104  void PrintSceneManagerInformation();
105 
110  void SetDeserializerLogVerbosity(const std::string& verbosityLevel);
111 
116  void SetInvokerLogVerbosity(const std::string& verbosityLevel);
117 
122  void SetObjectManagerLogVerbosity(const std::string& verbosityLevel);
123 
128  void SetSerializerLogVerbosity(const std::string& verbosityLevel);
129 
131 };
132 
133 VTK_ABI_NAMESPACE_END
134 #endif
struct vtkSessionImpl * vtkSession
Definition: vtkSession.h:91
A standalone session for managing VTK objects in a WebAssembly environment.
struct vtkSessionImpl * vtkSession