------------------------------------------------------------------------------
| 601 | |
| 602 | //------------------------------------------------------------------------------ |
| 603 | void vtkStringArray::InsertTuples(vtkIdList* dstIds, vtkIdList* srcIds, vtkAbstractArray* source) |
| 604 | { |
| 605 | vtkStringArray* sa = vtkArrayDownCast<vtkStringArray>(source); |
| 606 | if (!sa) |
| 607 | { |
| 608 | vtkWarningMacro("Input and outputs array data types do not match."); |
| 609 | return; |
| 610 | } |
| 611 | |
| 612 | if (this->NumberOfComponents != source->GetNumberOfComponents()) |
| 613 | { |
| 614 | vtkWarningMacro("Input and output component sizes do not match."); |
| 615 | return; |
| 616 | } |
| 617 | |
| 618 | vtkIdType numIds = dstIds->GetNumberOfIds(); |
| 619 | if (srcIds->GetNumberOfIds() != numIds) |
| 620 | { |
| 621 | vtkWarningMacro("Input and output id array sizes do not match."); |
| 622 | return; |
| 623 | } |
| 624 | |
| 625 | for (vtkIdType idIndex = 0; idIndex < numIds; ++idIndex) |
| 626 | { |
| 627 | vtkIdType numComp = this->NumberOfComponents; |
| 628 | vtkIdType srcLoc = srcIds->GetId(idIndex) * this->NumberOfComponents; |
| 629 | vtkIdType dstLoc = dstIds->GetId(idIndex) * this->NumberOfComponents; |
| 630 | while (numComp-- > 0) |
| 631 | { |
| 632 | this->InsertValue(dstLoc++, sa->GetValue(srcLoc++)); |
| 633 | } |
| 634 | } |
| 635 | |
| 636 | this->DataChanged(); |
| 637 | } |
| 638 | |
| 639 | //------------------------------------------------------------------------------ |
| 640 | void vtkStringArray::InsertTuplesStartingAt( |
nothing calls this directly
no test coverage detected