MCPcopy Create free account
hub / github.com/Kitware/VTK / GetNumberOfPieces

Method GetNumberOfPieces

IO/HDF/vtkHDFReaderImplementation.cxx:181–197  ·  view source on GitHub ↗

------------------------------------------------------------------------------

Source from the content-addressed store, hash-verified

179
180//------------------------------------------------------------------------------
181int vtkHDFReader::Implementation::GetNumberOfPieces(vtkIdType step)
182{
183 if (step < 0 || this->GetNumberOfSteps() == 1 ||
184 H5Lexists(this->VTKGroup, "Steps/NumberOfParts", H5P_DEFAULT) <= 0)
185 {
186 return this->NumberOfPieces;
187 }
188 std::vector<vtkIdType> buffer = this->GetMetadata("Steps/NumberOfParts", 1, step);
189 if (buffer.empty())
190 {
191 vtkErrorWithObjectMacro(
192 nullptr, "Could not read step " << step << " in NumberOfParts data set.");
193 return -1;
194 }
195 this->NumberOfPieces = buffer[0];
196 return this->NumberOfPieces;
197}
198
199//------------------------------------------------------------------------------
200void vtkHDFReader::Implementation::Close()

Callers 3

RequestDataObjectMethod · 0.45
ReadMethod · 0.45
ReadRecursivelyMethod · 0.45

Calls 3

GetNumberOfStepsMethod · 0.95
GetMetadataMethod · 0.95
emptyMethod · 0.45

Tested by

no test coverage detected