| 1191 | std::vector<std::tuple<std::string, Ioss::Field::BasicType, int>> Fields; |
| 1192 | |
| 1193 | vtkEntityBlock(vtkPartitionedDataSet* pds, vtkIOSSWriter::EntityType entityType, |
| 1194 | const std::string& name, const int blockId, int startSplitElementBlockId, |
| 1195 | vtkMultiProcessController* controller, vtkIOSSWriter* writer) |
| 1196 | : vtkGroupingEntity(writer) |
| 1197 | , DataSets(vtkCompositeDataSet::GetDataSets<vtkDataSet>(pds)) |
| 1198 | , RootName(name) |
| 1199 | , BlockId(blockId) |
| 1200 | , StartSplitElementBlockId(startSplitElementBlockId) |
| 1201 | { |
| 1202 | for (auto& ds : this->DataSets) |
| 1203 | { |
| 1204 | auto* gids = vtkIdTypeArray::SafeDownCast(ds->GetCellData()->GetGlobalIds()); |
| 1205 | if (!gids && ds->GetNumberOfCells() != 0) |
| 1206 | { |
| 1207 | throw std::runtime_error("cell global IDs missing!"); |
| 1208 | } |
| 1209 | } |
| 1210 | |
| 1211 | this->ElementCounts = ::GetElementCounts(pds, controller); |
| 1212 | this->Fields = ::GetFields(vtkDataObject::CELL, writer->GetChooseFieldsToWrite(), |
| 1213 | writer->GetFieldSelection(entityType), pds, controller); |
| 1214 | } |
| 1215 | |
| 1216 | void AppendMD5(vtksysMD5* md5) const override |
| 1217 | { |
nothing calls this directly
no test coverage detected