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

Method CheckUpstreamAbort

Common/ExecutionModel/vtkAlgorithm.cxx:277–301  ·  view source on GitHub ↗

------------------------------------------------------------------------------ Check to see if an input's ABORTED flag is set or if an upstream algorithm's AbortExecute is set. If either is set, return true. This is used by upstream algorithms to check for abort without setting any variables.

Source from the content-addressed store, hash-verified

275// This is used by upstream algorithms to check for abort without
276// setting any variables.
277bool vtkAlgorithm::CheckUpstreamAbort()
278{
279 if (this->GetAbortExecute())
280 {
281 this->LastAbortCheckTime.Modified();
282 return true;
283 }
284
285 if (this->LastAbortTime.GetMTime() > this->LastAbortCheckTime.GetMTime())
286 {
287 this->LastAbortCheckTime.Modified();
288 for (int port = 0; port < this->GetNumberOfInputPorts(); port++)
289 {
290 for (int index = 0; index < this->GetNumberOfInputConnections(port); index++)
291 {
292 if (this->GetInputAlgorithm(port, index)->CheckUpstreamAbort())
293 {
294 return true;
295 }
296 }
297 }
298 }
299
300 return this->GetAbortOutput();
301}
302
303//------------------------------------------------------------------------------
304void vtkAlgorithm::SetNoPriorTemporalAccessInformationKey()

Callers 1

CheckAbortMethod · 0.80

Calls 5

GetNumberOfInputPortsMethod · 0.95
GetInputAlgorithmMethod · 0.95
ModifiedMethod · 0.45
GetMTimeMethod · 0.45

Tested by

no test coverage detected