------------------------------------------------------------------------------ RequestInformation
| 11411 | //------------------------------------------------------------------------------ |
| 11412 | // RequestInformation |
| 11413 | int vtkOpenFOAMReader::RequestInformation(vtkInformation* vtkNotUsed(request), |
| 11414 | vtkInformationVector** vtkNotUsed(inputVector), vtkInformationVector* outputVector) |
| 11415 | { |
| 11416 | #if VTK_OPENFOAM_TIME_PROFILING |
| 11417 | this->InitializeRequestInformation(); |
| 11418 | #endif |
| 11419 | if (!this->FileName || !*(this->FileName)) |
| 11420 | { |
| 11421 | vtkErrorMacro("FileName has to be specified!"); |
| 11422 | return 0; |
| 11423 | } |
| 11424 | |
| 11425 | if (this->Parent == this && |
| 11426 | ((this->FileNameOld != this->FileName) || this->Refresh || |
| 11427 | (this->ListTimeStepsByControlDict != this->GetListTimeStepsByControlDictOld()) || |
| 11428 | (this->SkipZeroTime != this->GetSkipZeroTimeOld()))) |
| 11429 | { |
| 11430 | // Retain selection status when just refreshing a case |
| 11431 | if (!this->FileNameOld.empty() && this->FileNameOld != this->FileName) |
| 11432 | { |
| 11433 | // Clear selections |
| 11434 | this->CellDataArraySelection->RemoveAllArrays(); |
| 11435 | this->PointDataArraySelection->RemoveAllArrays(); |
| 11436 | this->LagrangianDataArraySelection->RemoveAllArrays(); |
| 11437 | this->PatchDataArraySelection->RemoveAllArrays(); |
| 11438 | } |
| 11439 | |
| 11440 | // Reset NumberOfReaders here so that the variable will not be |
| 11441 | // reset unwantedly when MakeInformationVector() is called from |
| 11442 | // vtkPOpenFOAMReader |
| 11443 | this->Readers.clear(); |
| 11444 | |
| 11445 | if (!this->MakeInformationVector(outputVector, {}) || !this->MakeMetaDataAtTimeStep(true)) |
| 11446 | { |
| 11447 | return 0; |
| 11448 | } |
| 11449 | this->Refresh = false; |
| 11450 | } |
| 11451 | return 1; |
| 11452 | } |
| 11453 | |
| 11454 | //------------------------------------------------------------------------------ |
| 11455 | // RequestData |
nothing calls this directly
no test coverage detected