Hap.emitSafe

void emitSafe(Args args, scope void delegate(Exception) @safe onError = null) @safe

Emit this hap while reporting handler exceptions and continuing dispatch.

Every handler captured at the start of dispatch is invoked. Exceptions are passed to onError when it is not null; otherwise they are ignored.

Parameters

argsArguments forwarded to each handler.
onErrorOptional exception callback.

Throws

Any exception thrown by onError.