Function emf_core_base_rs::global::sys::set_sync_handler [−][src]
pub unsafe fn set_sync_handler<L>(
_token: &mut LockToken<L>,
handler: Option<&impl SyncHandlerAPI<'static>>
)
Sets a new synchronization handler.
The default synchronization handler is used, if handler
is Option::None.
Uses
This function can be used by modules, that want to provide a more complex synchronization mechanism than the one presented by the default handler.
Swapping
The swapping occurs in three steps:
- The new synchronization handler is locked.
- The new synchronization handler is set as the active synchronization handler.
- The old synchronization handler is unlocked.
Safety
Changing the synchronization handler may break some modules, if they depend on a specific synchronization handler.