------------------------------------------------------------------------------
| 207 | |
| 208 | //------------------------------------------------------------------------------ |
| 209 | vtkInformationVector* vtkExecutive::GetOutputInformation() |
| 210 | { |
| 211 | // Use the shared output information vector if any is set. |
| 212 | if (this->SharedOutputInformation) |
| 213 | { |
| 214 | return this->SharedOutputInformation; |
| 215 | } |
| 216 | |
| 217 | // Use this executive's output information vector. |
| 218 | if (!this->Algorithm) |
| 219 | { |
| 220 | return nullptr; |
| 221 | } |
| 222 | // Set the length of the vector to match the number of ports. |
| 223 | int oldNumberOfPorts = this->OutputInformation->GetNumberOfInformationObjects(); |
| 224 | this->OutputInformation->SetNumberOfInformationObjects(this->GetNumberOfOutputPorts()); |
| 225 | |
| 226 | // For any new information objects, set the executive pointer and |
| 227 | // port number on the information object to tell it what produces |
| 228 | // it. |
| 229 | int nop = this->Algorithm->GetNumberOfOutputPorts(); |
| 230 | for (int i = oldNumberOfPorts; i < nop; ++i) |
| 231 | { |
| 232 | vtkInformation* info = this->OutputInformation->GetInformationObject(i); |
| 233 | vtkExecutive::PRODUCER()->Set(info, this, i); |
| 234 | } |
| 235 | |
| 236 | return this->OutputInformation; |
| 237 | } |
| 238 | |
| 239 | //------------------------------------------------------------------------------ |
| 240 | vtkInformation* vtkExecutive::GetOutputInformation(int port) |
no test coverage detected