VTK: Common/Core/vtkLongArray.h Source File

| VTK 9.3.1

vtkLongArray.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
20 #ifndef vtkLongArray_h
21 #define vtkLongArray_h
22
23 #include "vtkAOSDataArrayTemplate.h" // Real Superclass
24 #include "vtkCommonCoreModule.h" // For export macro
25 #include "vtkDataArray.h"
26
27 // Fake the superclass for the wrappers.
28 #ifndef __VTK_WRAP__
29 #define vtkDataArray vtkAOSDataArrayTemplate<long>
30 #endif
31 VTK_ABI_NAMESPACE_BEGIN
32 class VTKCOMMONCORE_EXPORT vtkLongArray : public vtkDataArray
33 {
34 public:
35 vtkTypeMacro(vtkLongArray, vtkDataArray);
36 #ifndef __VTK_WRAP__
37 #undef vtkDataArray
38 #endif
39 static vtkLongArray* New();
40 static vtkLongArray* ExtendedNew();
41 void PrintSelf(ostream& os, vtkIndent indent) override;
42
43 // This macro expands to the set of method declarations that
44 // make up the interface of vtkAOSDataArrayTemplate, which is ignored
45 // by the wrappers.
46 #if defined(__VTK_WRAP__) || defined(__WRAP_GCCXML__)
47 vtkCreateWrappedArrayInterface(long);
48 #endif
49
53 static vtkLongArray* FastDownCast(vtkAbstractArray* source)
54 {
55 return static_cast<vtkLongArray*>(Superclass::FastDownCast(source));
56 }
57
61 static long GetDataTypeValueMin() { return VTK_LONG_MIN; }
62
66 static long GetDataTypeValueMax() { return VTK_LONG_MAX; }
67
68 protected:
69 vtkLongArray();
70 ~vtkLongArray() override;
71
72 private:
73 typedef vtkAOSDataArrayTemplate<long> RealSuperclass;
74
75 vtkLongArray(const vtkLongArray&) = delete;
76 void operator=(const vtkLongArray&) = delete;
77 };
78
79 // Define vtkArrayDownCast implementation:
80 vtkArrayDownCast_FastCastMacro(vtkLongArray);
81
82 VTK_ABI_NAMESPACE_END
83 #endif
vtkAOSDataArrayTemplate< long >
vtkAbstractArray
Abstract superclass for all arrays.
Definition: vtkAbstractArray.h:76
vtkDataArray
abstract superclass for arrays of numeric data
Definition: vtkDataArray.h:54
vtkIndent
a simple class to control print indentation
Definition: vtkIndent.h:38
vtkLongArray
dynamic, self-adjusting array of long
Definition: vtkLongArray.h:33
vtkLongArray::GetDataTypeValueMin
static long GetDataTypeValueMin()
Get the minimum data value in its native type.
Definition: vtkLongArray.h:61
vtkLongArray::New
static vtkLongArray * New()
vtkLongArray::ExtendedNew
static vtkLongArray * ExtendedNew()
vtkLongArray::PrintSelf
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
vtkLongArray::~vtkLongArray
~vtkLongArray() override
vtkLongArray::vtkLongArray
vtkLongArray()
vtkLongArray::FastDownCast
static vtkLongArray * FastDownCast(vtkAbstractArray *source)
A faster alternative to SafeDownCast for downcasting vtkAbstractArrays.
Definition: vtkLongArray.h:53
vtkLongArray::GetDataTypeValueMax
static long GetDataTypeValueMax()
Get the maximum data value in its native type.
Definition: vtkLongArray.h:66
vtkAOSDataArrayTemplate.h
vtkCreateWrappedArrayInterface
#define vtkCreateWrappedArrayInterface(T)
Definition: vtkAOSDataArrayTemplate.h:298
source
boost::graph_traits< vtkGraph * >::vertex_descriptor source(boost::graph_traits< vtkGraph * >::edge_descriptor e, vtkGraph *)
Definition: vtkBoostGraphAdapter.h:964
vtkDataArray.h
vtkArrayDownCast_FastCastMacro
vtkArrayDownCast_FastCastMacro(vtkLongArray)
VTK_LONG_MAX
#define VTK_LONG_MAX
Definition: vtkType.h:148
VTK_LONG_MIN
#define VTK_LONG_MIN
Definition: vtkType.h:147