33 #include "vtkCommonCoreModule.h" 48 int Allocate(
const vtkIdType sz,
const int strategy=0);
63 {
return this->Ids[i];}
69 void SetNumberOfIds(
const vtkIdType number);
78 {this->Ids[i] = vtkid;}
120 void Reset() {this->NumberOfIds = 0;};
125 void Squeeze() {this->Resize(this->NumberOfIds);};
157 this->IntersectWith(&otherIds); };
169 void operator=(
const vtkIdList&) =
delete;
179 this->Ids[i] = vtkid;
180 if (i >= this->NumberOfIds)
182 this->NumberOfIds = i + 1;
189 if ( this->NumberOfIds >= this->Size )
191 if (!this->Resize(2*this->NumberOfIds+1))
193 return this->NumberOfIds-1;
196 this->Ids[this->NumberOfIds++] = vtkid;
197 return this->NumberOfIds-1;
203 for (ptr=this->Ids, i=0; i<this->NumberOfIds; i++, ptr++)
void InsertId(const vtkIdType i, const vtkIdType vtkid)
Set the id at location i.
abstract base class for most VTK objects
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
void Squeeze()
Free any unused memory.
void SetId(const vtkIdType i, const vtkIdType vtkid)
Set the id at location i.
void Reset()
Reset to an empty state.
vtkIdType GetNumberOfIds()
Return the number of id's in the list.
void IntersectWith(vtkIdList &otherIds)
a simple class to control print indentation
list of point or cell ids
vtkIdType IsId(vtkIdType vtkid)
Return -1 if id specified is not contained in the list; otherwise return the position in the list...
vtkIdType GetId(const vtkIdType i)
Return the id at location i.
static vtkObject * New()
Create an object with Debug turned off, modified time initialized to zero, and reference counting on...
vtkIdType InsertNextId(const vtkIdType vtkid)
Add the id specified to the end of the list.
vtkIdType * GetPointer(const vtkIdType i)
Get a pointer to a particular data index.