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

Method deserialize

Serialization/Manager/Testing/Python/TestDynamic.py:55–80  ·  view source on GitHub ↗
(status: dict)

Source from the content-addressed store, hash-verified

53 return status
54
55 def deserialize(status: dict):
56
57 if not len(status.get('ids')):
58 return
59
60 deser_om.PruneUnusedBlobs()
61
62 for object_id in status.get('ids'):
63 new_mtime = status.get('mtimes').get(object_id)
64 last_mtime = last_mtimes.get(object_id)
65 if last_mtime is not None and new_mtime is not None:
66 if last_mtime < new_mtime:
67 deser_om.UnRegisterState(object_id)
68 deser_om.RegisterState(ser_om.GetState(object_id))
69 elif last_mtime is None:
70 deser_om.RegisterState(ser_om.GetState(object_id))
71 last_mtimes.update({object_id: new_mtime})
72 for hash_text, blob in status.get('hashes').items():
73 deser_om.RegisterBlob(hash_text, blob)
74
75 deser_om.UpdateObjectsFromStates()
76 active_ids = deser_om.GetAllDependencies(0)
77
78 renderWindow = deser_om.GetObjectAtId(id_rwi).GetRenderWindow()
79 renderWindow.SetPosition(400, 1)
80 renderWindow.Render()
81
82 id_rwi = ser_om.RegisterObject(rwi)
83

Callers

nothing calls this directly

Calls 14

RenderMethod · 0.65
getMethod · 0.45
PruneUnusedBlobsMethod · 0.45
UnRegisterStateMethod · 0.45
RegisterStateMethod · 0.45
GetStateMethod · 0.45
updateMethod · 0.45
itemsMethod · 0.45
RegisterBlobMethod · 0.45
GetAllDependenciesMethod · 0.45
GetRenderWindowMethod · 0.45

Tested by

no test coverage detected