------------------------------------------------------------------------------
| 883 | |
| 884 | //------------------------------------------------------------------------------ |
| 885 | void vtkObjectManager::UpdateStateFromObject(vtkTypeUInt32 identifier) |
| 886 | { |
| 887 | if (auto object = this->Context->GetObjectAtId(identifier)) |
| 888 | { |
| 889 | // clear dependency tree for this object. |
| 890 | // This lets the serializer see that the object is not processed |
| 891 | // in the marshalling context. |
| 892 | this->Context->ResetDirectDependenciesForNode(identifier); |
| 893 | const auto id = this->Serializer->SerializeJSON(object); |
| 894 | if (id.empty()) |
| 895 | { |
| 896 | vtkErrorMacro(<< "Failed to update state for object at id=" << identifier); |
| 897 | } |
| 898 | else |
| 899 | { |
| 900 | vtkVLog( |
| 901 | this->GetObjectManagerLogVerbosity(), << "Updated state for object at id=" << identifier); |
| 902 | } |
| 903 | } |
| 904 | else |
| 905 | { |
| 906 | vtkErrorMacro(<< "Cannot update state for object at id=" << identifier |
| 907 | << " because there is no such object!"); |
| 908 | } |
| 909 | } |
| 910 | |
| 911 | //------------------------------------------------------------------------------ |
| 912 | void vtkObjectManager::SetObjectManagerLogVerbosity(vtkLogger::Verbosity verbosity) |