-
class neuroglancer.trackable_state.TrackableState[State](
ChangeNotifier) State object that supports registering change notification callbacks.
Public members¶
-
TrackableState(wrapper_type, transform_state=
None
) Initialize self. See help(type(self)) for accurate signature.
-
txn(overwrite: bool =
False
, lock: bool =True
) Context manager for a state modification transaction.
- add_changed_callback(callback: Callable[[], None])
Registers a callback to be invoked when the state changes.
- remove_changed_callback(callback: Callable[[], None])
Removes a previously-registered callback.
- change_count: int
Total number of changes that have occurred.
-
TrackableState(wrapper_type, transform_state=