| 1811 | } |
| 1812 | |
| 1813 | void Model(Ioss::Region& region) const override |
| 1814 | { |
| 1815 | auto entity = this->GetEntity(region, this->Name); |
| 1816 | |
| 1817 | std::vector<int32_t> elementSide; |
| 1818 | elementSide.reserve(this->Count * 2); |
| 1819 | |
| 1820 | const bool removeGhosts = this->Writer->GetRemoveGhosts(); |
| 1821 | for (auto& ds : this->DataSets) |
| 1822 | { |
| 1823 | if (ds->GetNumberOfCells() == 0) |
| 1824 | { |
| 1825 | continue; |
| 1826 | } |
| 1827 | auto elemSideArray = vtkIntArray::SafeDownCast(ds->GetCellData()->GetArray("element_side")); |
| 1828 | vtkUnsignedCharArray* ghost = ds->GetCellGhostArray(); |
| 1829 | const auto elementSideRange = vtk::DataArrayTupleRange(elemSideArray); |
| 1830 | for (vtkIdType cc = 0; cc < elementSideRange.size(); ++cc) |
| 1831 | { |
| 1832 | const bool process = !removeGhosts || !ghost || ghost->GetValue(cc) == 0; |
| 1833 | if (process) |
| 1834 | { |
| 1835 | for (const auto& comp : elementSideRange[cc]) |
| 1836 | { |
| 1837 | elementSide.push_back(comp); |
| 1838 | } |
| 1839 | } |
| 1840 | } |
| 1841 | } |
| 1842 | |
| 1843 | assert(elementSide.size() == static_cast<size_t>(this->Count * 2)); |
| 1844 | entity->put_field_data("element_side", elementSide); |
| 1845 | } |
| 1846 | |
| 1847 | void Transient(Ioss::Region& region) const override |
| 1848 | { |
nothing calls this directly
no test coverage detected