Registration that can detach this exact registered handler.Hap.register
Registration!Handler register(Handler handler) @safeRegister a delegate handler and return a detachable Registration.
Unlike attach, register returns a Registration that can detach exactly the registered handler by identity, even when the same handler was registered multiple times.
Parameters
handler | Delegate handler to register; null returns an inert registration. |
Returns
A
Registration!Handler register(FunctionHandler handler) @safeRegister a free-function handler and return a detachable registration.
Parameters
handler | Free-function handler to register; null returns an inert registration. |
Returns
A
Registration that can detach this exact registered handler.