VTK
dox/Common/Core/vtkIntArray.h
Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program:   Visualization Toolkit
00004   Module:    vtkIntArray.h
00005 
00006   Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
00007   All rights reserved.
00008   See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
00009 
00010      This software is distributed WITHOUT ANY WARRANTY; without even
00011      the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
00012      PURPOSE.  See the above copyright notice for more information.
00013 
00014 =========================================================================*/
00029 #ifndef __vtkIntArray_h
00030 #define __vtkIntArray_h
00031 
00032 // Tell the template header how to give our superclass a DLL interface.
00033 #if !defined(__vtkIntArray_cxx) && (defined(VTK_USE_64BIT_IDS) || !defined(__vtkIdTypeArray_h))
00034 # define VTK_DATA_ARRAY_TEMPLATE_TYPE int
00035 #endif
00036 
00037 #include "vtkCommonCoreModule.h" // For export macro
00038 #include "vtkDataArray.h"
00039 #include "vtkDataArrayTemplate.h" // Real Superclass
00040 
00041 // Fake the superclass for the wrappers.
00042 #define vtkDataArray vtkDataArrayTemplate<int>
00043 class VTKCOMMONCORE_EXPORT vtkIntArray : public vtkDataArray
00044 #undef vtkDataArray
00045 {
00046 public:
00047   static vtkIntArray* New();
00048   vtkTypeMacro(vtkIntArray,vtkDataArray);
00049   void PrintSelf(ostream& os, vtkIndent indent);
00050 
00052 
00053   int GetDataType()
00054     { return VTK_INT; }
00056 
00058 
00059   void GetTupleValue(vtkIdType i, int* tuple)
00060     { this->RealSuperclass::GetTupleValue(i, tuple); }
00062 
00064 
00065   void SetTupleValue(vtkIdType i, const int* tuple)
00066     { this->RealSuperclass::SetTupleValue(i, tuple); }
00068 
00070 
00072   void InsertTupleValue(vtkIdType i, const int* tuple)
00073     { this->RealSuperclass::InsertTupleValue(i, tuple); }
00075 
00077 
00079   vtkIdType InsertNextTupleValue(const int* tuple)
00080     { return this->RealSuperclass::InsertNextTupleValue(tuple); }
00082 
00084 
00085   int GetValue(vtkIdType id)
00086     { return this->RealSuperclass::GetValue(id); }
00088 
00090 
00092   void SetValue(vtkIdType id, int value)
00093     { this->RealSuperclass::SetValue(id, value); }
00095 
00097 
00100   void SetNumberOfValues(vtkIdType number)
00101     { this->RealSuperclass::SetNumberOfValues(number); }
00103 
00105 
00106   void InsertValue(vtkIdType id, int f)
00107     { this->RealSuperclass::InsertValue(id, f); }
00109 
00111 
00113   vtkIdType InsertNextValue(int f)
00114     { return this->RealSuperclass::InsertNextValue(f); }
00116 
00118 
00120   int *GetValueRange(int comp)
00121     { return this->RealSuperclass::GetValueRange(comp); }
00122 //BTX
00123   void GetValueRange(int range[2], int comp)
00124     { this->RealSuperclass::GetValueRange(range, comp); }
00125 //ETX
00127 
00129 
00131   int *GetValueRange()
00132     { return this->RealSuperclass::GetValueRange(0); }
00133 //BTX
00134   void GetValueRange(int range[2])
00135     { this->RealSuperclass::GetValueRange(range, 0); }
00136 //ETX
00138 
00140   static int GetDataTypeValueMin() { return VTK_INT_MIN; }
00141 
00143   static int GetDataTypeValueMax() { return VTK_INT_MAX; }
00144 
00146 
00149   int* WritePointer(vtkIdType id, vtkIdType number)
00150     { return this->RealSuperclass::WritePointer(id, number); }
00152 
00154 
00156   int* GetPointer(vtkIdType id)
00157     { return this->RealSuperclass::GetPointer(id); }
00159 
00161 
00167   void SetArray(int* array, vtkIdType size, int save)
00168     { this->RealSuperclass::SetArray(array, size, save); }
00169   void SetArray(int* array, vtkIdType size, int save, int deleteMethod)
00170     { this->RealSuperclass::SetArray(array, size, save, deleteMethod); }
00172 
00173 protected:
00174   vtkIntArray(vtkIdType numComp=1);
00175   ~vtkIntArray();
00176 
00177 private:
00178   //BTX
00179   typedef vtkDataArrayTemplate<int> RealSuperclass;
00180   //ETX
00181   vtkIntArray(const vtkIntArray&);  // Not implemented.
00182   void operator=(const vtkIntArray&);  // Not implemented.
00183 };
00184 
00185 #endif