VTK  9.3.1
vtkAnnotationLayers.h
Go to the documentation of this file.
1 // SPDX-FileCopyrightText: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
2 // SPDX-FileCopyrightText: Copyright 2008 Sandia Corporation
3 // SPDX-License-Identifier: LicenseRef-BSD-3-Clause-Sandia-USGov
4 
16 #ifndef vtkAnnotationLayers_h
17 #define vtkAnnotationLayers_h
18 
19 #include "vtkCommonDataModelModule.h" // For export macro
20 #include "vtkDataObject.h"
21 
22 VTK_ABI_NAMESPACE_BEGIN
23 class vtkAnnotation;
24 class vtkSelection;
25 
26 class VTKCOMMONDATAMODEL_EXPORT vtkAnnotationLayers : public vtkDataObject
27 {
28 public:
30  void PrintSelf(ostream& os, vtkIndent indent) override;
31  static vtkAnnotationLayers* New();
32 
36  int GetDataObjectType() override { return VTK_ANNOTATION_LAYERS; }
37 
39 
42  virtual void SetCurrentAnnotation(vtkAnnotation* ann);
43  vtkGetObjectMacro(CurrentAnnotation, vtkAnnotation);
45 
47 
51  virtual void SetCurrentSelection(vtkSelection* sel);
52  virtual vtkSelection* GetCurrentSelection();
54 
58  unsigned int GetNumberOfAnnotations();
59 
63  vtkAnnotation* GetAnnotation(unsigned int idx);
64 
68  void AddAnnotation(vtkAnnotation* ann);
69 
73  void RemoveAnnotation(vtkAnnotation* ann);
74 
78  void Initialize() override;
79 
84  void ShallowCopy(vtkDataObject* other) override;
85 
90  void DeepCopy(vtkDataObject* other) override;
91 
93 
97  static vtkAnnotationLayers* GetData(vtkInformationVector* v, int i = 0);
99 
103  vtkMTimeType GetMTime() override;
104 
105 protected:
107  ~vtkAnnotationLayers() override;
108 
109  class Internals;
110  Internals* Implementation;
112 
113 private:
114  vtkAnnotationLayers(const vtkAnnotationLayers&) = delete;
115  void operator=(const vtkAnnotationLayers&) = delete;
116 };
117 
118 VTK_ABI_NAMESPACE_END
119 #endif
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
static vtkDataObject * GetData(vtkInformation *info)
Retrieve an instance of this class from an information object.
static vtkDataObject * New()
Store vtkAlgorithm input/output information.
vtkTypeUInt32 vtkMTimeType
Definition: vtkType.h:270
data object that represents a "selection" in VTK.
Definition: vtkSelection.h:49
virtual void Initialize()
Restore data object to initial state,.
vtkAnnotation * CurrentAnnotation
a simple class to control print indentation
Definition: vtkIndent.h:28
#define VTK_ANNOTATION_LAYERS
Definition: vtkType.h:110
Stores a collection of annotation artifacts.
Definition: vtkAnnotation.h:32
Stores a ordered collection of annotation sets.
int GetDataObjectType() override
Returns VTK_ANNOTATION.
Store zero or more vtkInformation instances.
vtkMTimeType GetMTime() override
Data objects are composite objects and need to check each part for MTime.
general representation of visualization data
Definition: vtkDataObject.h:54
virtual void DeepCopy(vtkDataObject *src)
The goal of the method is to copy the complete data from src into this object.
virtual void ShallowCopy(vtkDataObject *src)
The goal of the method is to copy the data up to the array pointers only.