VTK  9.7.1
vtkConduitSource.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
21 #ifndef vtkConduitSource_h
22 #define vtkConduitSource_h
23 
24 #include "vtkDataObjectAlgorithm.h"
25 
26 #include "vtkIOCatalystConduitModule.h" // for exports
27 
28 #include "conduit.h" // for conduit_node
29 
30 #include <memory> // for std::unique_ptr
31 
32 VTK_ABI_NAMESPACE_BEGIN
33 class VTKIOCATALYSTCONDUIT_EXPORT vtkConduitSource : public vtkDataObjectAlgorithm
34 {
35 public:
36  static vtkConduitSource* New();
38  void PrintSelf(ostream& os, vtkIndent indent) override;
39 
41 
46  vtkSetMacro(UseAMRMeshProtocol, bool);
47  vtkGetMacro(UseAMRMeshProtocol, bool);
48  vtkBooleanMacro(UseAMRMeshProtocol, bool);
50 
52 
57  vtkSetMacro(UseMultiMeshProtocol, bool);
58  vtkGetMacro(UseMultiMeshProtocol, bool);
59  vtkBooleanMacro(UseMultiMeshProtocol, bool);
61 
63 
67  vtkSetMacro(OutputMultiBlock, bool);
68  vtkGetMacro(OutputMultiBlock, bool);
69  vtkBooleanMacro(OutputMultiBlock, bool);
71 
73 
77  void SetNode(const conduit_node* node);
79 
81 
89  void SetGlobalFieldsNode(const conduit_node* node);
91 
93 
96  void SetAssemblyNode(const conduit_node* node);
98 
99 protected:
101  ~vtkConduitSource() override;
102 
105  int RequestInformation(vtkInformation* request, vtkInformationVector** inputVector,
106  vtkInformationVector* outputVector) override;
107 
109 
113  bool GenerateAMR(vtkDataObject* output);
114  bool GeneratePartitionedDataSet(vtkDataObject* output);
115  bool GeneratePartitionedDataSetCollection(vtkDataObject* output);
117 
118 private:
119  vtkConduitSource(const vtkConduitSource&) = delete;
120  void operator=(const vtkConduitSource&) = delete;
121 
122  class vtkInternals;
123  std::unique_ptr<vtkInternals> Internals;
124  bool UseAMRMeshProtocol;
125  bool UseMultiMeshProtocol;
126  bool OutputMultiBlock;
127 };
128 VTK_ABI_NAMESPACE_END
129 
130 #endif
virtual int RequestDataObject(vtkInformation *, vtkInformationVector **, vtkInformationVector *)
This is called by the superclass.
struct conduit_node_impl conduit_node
Store vtkAlgorithm input/output information.
static vtkDataObjectAlgorithm * New()
data source for Conduit Mesh Blueprint.
a simple class to control print indentation
Definition: vtkIndent.h:28
Superclass for algorithms that produce only data object as output.
virtual int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *)
virtual int RequestInformation(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector)
Store zero or more vtkInformation instances.
general representation of visualization data
Definition: vtkDataObject.h:55
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.