VTK  9.6.20260319
vtkShortArray.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
37
38#ifndef vtkShortArray_h
39#define vtkShortArray_h
40
41#include "vtkAOSDataArrayTemplate.h" // Real Superclass
42#include "vtkCommonCoreModule.h" // For export macro
43#include "vtkDataArray.h"
44
45// Fake the superclass for non-Python wrappers.
46// Python can handle the templated superclass; Java and others cannot.
47#if !defined(__VTK_WRAP__) || defined(__VTK_WRAP_PYTHON__)
48#define vtkDataArray vtkAOSDataArrayTemplate<short>
49#endif
50VTK_ABI_NAMESPACE_BEGIN
51class VTKCOMMONCORE_EXPORT vtkShortArray : public vtkDataArray
52{
53public:
55#if !defined(__VTK_WRAP__) || defined(__VTK_WRAP_PYTHON__)
56#undef vtkDataArray
57#endif
58 static vtkShortArray* New();
60 void PrintSelf(ostream& os, vtkIndent indent) override;
61
62 // This macro expands to the set of method declarations that
63 // make up the interface of vtkAOSDataArrayTemplate, which is ignored
64 // by the wrappers.
65#if (defined(__VTK_WRAP__) || defined(__WRAP_GCCXML__)) && !defined(__VTK_WRAP_PYTHON__)
67#endif
68
76
77protected:
79 ~vtkShortArray() override;
80
81private:
82 typedef vtkAOSDataArrayTemplate<short> RealSuperclass;
83
84 vtkShortArray(const vtkShortArray&) = delete;
85 void operator=(const vtkShortArray&) = delete;
86};
87
88// Define vtkArrayDownCast implementation:
90
91VTK_ABI_NAMESPACE_END
92#endif
Abstract superclass for all arrays.
static vtkDataArray * FastDownCast(vtkAbstractArray *source)
Perform a fast, safe cast from a vtkAbstractArray to a vtkDataArray.
a simple class to control print indentation
Definition vtkIndent.h:108
dynamic, self-adjusting array of short
~vtkShortArray() override
static vtkShortArray * FastDownCast(vtkAbstractArray *source)
A faster alternative to SafeDownCast for downcasting vtkAbstractArrays.
static vtkShortArray * ExtendedNew()
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
static vtkShortArray * New()
#define vtkCreateWrappedArrayInterface(T)
#define vtkArrayDownCast_FastCastMacro(ArrayT)
This macro is used to tell vtkArrayDownCast to use FastDownCast instead of SafeDownCast.
boost::graph_traits< vtkGraph * >::vertex_descriptor source(boost::graph_traits< vtkGraph * >::edge_descriptor e, vtkGraph *)
#define vtkDataArray