| 222 | } |
| 223 | |
| 224 | bool documentCanRecomputeOnWorker(const Document& document) |
| 225 | { |
| 226 | try { |
| 227 | const auto& objects = document.getObjects(); |
| 228 | std::vector<DocumentObject*> recomputeRoots(objects.begin(), objects.end()); |
| 229 | const auto recomputeObjects = Document::getDependencyList(recomputeRoots, Document::DepSort); |
| 230 | |
| 231 | return std::ranges::all_of(recomputeObjects, [](const DocumentObject* object) { |
| 232 | return object && object->canRecomputeOnWorker(); |
| 233 | }); |
| 234 | } |
| 235 | catch (const Base::BadGraphError&) { |
| 236 | return false; |
| 237 | } |
| 238 | } |
| 239 | |
| 240 | void reportRecomputeException(const Base::Exception& exception) |
| 241 | { |
no test coverage detected