VTK
vtkUnicodeStringArray.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkUnicodeStringArray.h
5 
6 -------------------------------------------------------------------------
7  Copyright 2008 Sandia Corporation.
8  Under the terms of Contract DE-AC04-94AL85000 with Sandia Corporation,
9  the U.S. Government retains certain rights in this software.
10 -------------------------------------------------------------------------
11 
12  Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
13  All rights reserved.
14  See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
15 
16  This software is distributed WITHOUT ANY WARRANTY; without even
17  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
18  PURPOSE. See the above copyright notice for more information.
19 
20 =========================================================================*/
21 
34 #ifndef __vtkUnicodeStringArray_h
35 #define __vtkUnicodeStringArray_h
36 
37 #include "vtkAbstractArray.h"
38 #include "vtkUnicodeString.h" // For value type
39 
41  public vtkAbstractArray
42 {
43 public:
44  static vtkUnicodeStringArray* New();
46  void PrintSelf(ostream& os, vtkIndent indent);
47 
48  virtual int Allocate(vtkIdType sz, vtkIdType ext=1000);
49  virtual void Initialize();
50  virtual int GetDataType();
51  virtual int GetDataTypeSize();
52  virtual int GetElementComponentSize();
53  virtual void SetNumberOfTuples(vtkIdType number);
54  virtual void SetTuple(vtkIdType i, vtkIdType j, vtkAbstractArray* source);
55  virtual void InsertTuple(vtkIdType i, vtkIdType j, vtkAbstractArray* source);
57  virtual void* GetVoidPointer(vtkIdType id);
58  virtual void DeepCopy(vtkAbstractArray* da);
59  virtual void InterpolateTuple(vtkIdType i, vtkIdList *ptIndices,
60  vtkAbstractArray* source, double* weights);
61  virtual void InterpolateTuple(vtkIdType i,
62  vtkIdType id1, vtkAbstractArray* source1,
63  vtkIdType id2, vtkAbstractArray* source2, double t);
64  virtual void Squeeze();
65  virtual int Resize(vtkIdType numTuples);
66  virtual void SetVoidArray(void *array, vtkIdType size, int save);
67  virtual unsigned long GetActualMemorySize();
68  virtual int IsNumeric();
69  virtual vtkArrayIterator* NewIterator();
71  virtual vtkIdType LookupValue(vtkVariant value);
72  virtual void LookupValue(vtkVariant value, vtkIdList* ids);
73 
74  virtual void SetVariantValue(vtkIdType idx, vtkVariant value);
75  virtual void DataChanged();
76  virtual void ClearLookup();
77 
78  vtkIdType InsertNextValue(const vtkUnicodeString&);
79  void InsertValue(vtkIdType idx, const vtkUnicodeString&); // Ranged checked
80  void SetValue(vtkIdType i, const vtkUnicodeString&); // Not ranged checked
81  vtkUnicodeString& GetValue(vtkIdType i);
82 
83  void InsertNextUTF8Value(const char*);
84  void SetUTF8Value(vtkIdType i, const char*);
85  const char* GetUTF8Value(vtkIdType i);
86 
87 protected:
88  vtkUnicodeStringArray(vtkIdType numComp = 1);
90 
91 private:
92  vtkUnicodeStringArray(const vtkUnicodeStringArray&); // Not implemented.
93  void operator=(const vtkUnicodeStringArray&); // Not implemented.
94 
95 //BTX
96  class Implementation;
97  Implementation* Internal;
98 //ETX
99 };
100 
101 #endif
102