VTK
vtkLongArray.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkLongArray.h
5 
6  Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
7  All rights reserved.
8  See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
9 
10  This software is distributed WITHOUT ANY WARRANTY; without even
11  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12  PURPOSE. See the above copyright notice for more information.
13 
14 =========================================================================*/
26 #ifndef __vtkLongArray_h
27 #define __vtkLongArray_h
28 
29 // Tell the template header how to give our superclass a DLL interface.
30 #if !defined(__vtkLongArray_cxx)
31 # define VTK_DATA_ARRAY_TEMPLATE_TYPE long
32 #endif
33 
34 #include "vtkDataArray.h"
35 #include "vtkDataArrayTemplate.h" // Real Superclass
36 
37 // Fake the superclass for the wrappers.
38 #define vtkDataArray vtkDataArrayTemplate<long>
40 #undef vtkDataArray
41 {
42 public:
43  static vtkLongArray* New();
44  vtkTypeMacro(vtkLongArray,vtkDataArray);
45  void PrintSelf(ostream& os, vtkIndent indent);
46 
48 
50  { return VTK_LONG; }
52 
54 
55  void GetTupleValue(vtkIdType i, long* tuple)
56  { this->RealSuperclass::GetTupleValue(i, tuple); }
58 
60 
61  void SetTupleValue(vtkIdType i, const long* tuple)
62  { this->RealSuperclass::SetTupleValue(i, tuple); }
64 
66 
68  void InsertTupleValue(vtkIdType i, const long* tuple)
69  { this->RealSuperclass::InsertTupleValue(i, tuple); }
71 
73 
75  vtkIdType InsertNextTupleValue(const long* tuple)
76  { return this->RealSuperclass::InsertNextTupleValue(tuple); }
78 
80 
82  { return this->RealSuperclass::GetValue(id); }
84 
86 
88  void SetValue(vtkIdType id, long value)
89  { this->RealSuperclass::SetValue(id, value); }
91 
93 
97  { this->RealSuperclass::SetNumberOfValues(number); }
99 
101 
102  void InsertValue(vtkIdType id, long f)
103  { this->RealSuperclass::InsertValue(id, f); }
105 
107 
110  { return this->RealSuperclass::InsertNextValue(f); }
112 
114 
116  long *GetValueRange(int comp)
117  { return this->RealSuperclass::GetValueRange(comp); }
118 //BTX
119  void GetValueRange(long range[2], int comp)
120  { this->RealSuperclass::GetValueRange(range, comp); }
121 //ETX
123 
125 
128  { return this->RealSuperclass::GetValueRange(0); }
129 //BTX
130  void GetValueRange(long range[2])
131  { this->RealSuperclass::GetValueRange(range, 0); }
132 //ETX
134 
136  static long GetDataTypeValueMin() { return VTK_LONG_MIN; }
137 
139  static long GetDataTypeValueMax() { return VTK_LONG_MAX; }
140 
142 
145  long* WritePointer(vtkIdType id, vtkIdType number)
146  { return this->RealSuperclass::WritePointer(id, number); }
148 
150 
153  { return this->RealSuperclass::GetPointer(id); }
155 
157 
163  void SetArray(long* array, vtkIdType size, int save)
164  { this->RealSuperclass::SetArray(array, size, save); }
165  void SetArray(long* array, vtkIdType size, int save, int deleteMethod)
166  { this->RealSuperclass::SetArray(array, size, save, deleteMethod); }
168 
169 protected:
170  vtkLongArray(vtkIdType numComp=1);
171  ~vtkLongArray();
172 
173 private:
174  //BTX
175  typedef vtkDataArrayTemplate<long> RealSuperclass;
176  //ETX
177  vtkLongArray(const vtkLongArray&); // Not implemented.
178  void operator=(const vtkLongArray&); // Not implemented.
179 };
180 
181 #endif
void GetTupleValue(vtkIdType i, long *tuple)
Definition: vtkLongArray.h:55
void SetNumberOfValues(vtkIdType number)
Definition: vtkLongArray.h:96
Implementation template for vtkDataArray.
void GetValueRange(long range[2])
Definition: vtkLongArray.h:130
dynamic, self-adjusting array of long
Definition: vtkLongArray.h:39
long * GetValueRange()
Definition: vtkLongArray.h:127
long * GetPointer(vtkIdType id)
Definition: vtkLongArray.h:152
vtkIdType InsertNextValue(long f)
Definition: vtkLongArray.h:109
void SetArray(long *array, vtkIdType size, int save)
Definition: vtkLongArray.h:163
int vtkIdType
Definition: vtkType.h:255
long * WritePointer(vtkIdType id, vtkIdType number)
Definition: vtkLongArray.h:145
void InsertValue(vtkIdType id, long f)
Definition: vtkLongArray.h:102
void SetArray(long *array, vtkIdType size, int save, int deleteMethod)
Definition: vtkLongArray.h:165
long * GetValueRange(int comp)
Definition: vtkLongArray.h:116
a simple class to control print indentation
Definition: vtkIndent.h:37
abstract superclass for arrays of numeric data
Definition: vtkDataArray.h:53
#define VTK_LONG
Definition: vtkType.h:33
#define VTK_COMMON_EXPORT
#define VTK_LONG_MIN
Definition: vtkType.h:126
static long GetDataTypeValueMax()
Definition: vtkLongArray.h:139
void save(Archiver &ar, const vtkVariant &variant, const unsigned int vtkNotUsed(version))
void SetValue(vtkIdType id, long value)
Definition: vtkLongArray.h:88
void PrintSelf(ostream &os, vtkIndent indent)
int GetDataType()
Definition: vtkLongArray.h:49
void GetValueRange(long range[2], int comp)
Definition: vtkLongArray.h:119
void InsertTupleValue(vtkIdType i, const long *tuple)
Definition: vtkLongArray.h:68
static vtkObject * New()
static long GetDataTypeValueMin()
Definition: vtkLongArray.h:136
void SetTupleValue(vtkIdType i, const long *tuple)
Definition: vtkLongArray.h:61
#define VTK_LONG_MAX
Definition: vtkType.h:127
long GetValue(vtkIdType id)
Definition: vtkLongArray.h:81
vtkIdType InsertNextTupleValue(const long *tuple)
Definition: vtkLongArray.h:75