Documentation - v7.14.0
    Preparing search index...

    Variable callMonitoredConst

    callMonitored: {
        <T extends (...args: any[]) => unknown>(
            fn: T,
            context: ThisParameterType<T>,
            args: Parameters<T>,
        ): ReturnType<T> | undefined;
        <T extends (this: void) => unknown>(fn: T): ReturnType<T> | undefined;
    } = globalMonitor.callMonitored

    Invoke-with-error-handling backed by the global monitor. See Monitor.callMonitored for semantics and usage.

    Type Declaration

      • <T extends (...args: any[]) => unknown>(
            fn: T,
            context: ThisParameterType<T>,
            args: Parameters<T>,
        ): ReturnType<T> | undefined
      • Type Parameters

        • T extends (...args: any[]) => unknown

        Parameters

        • fn: T
        • context: ThisParameterType<T>
        • args: Parameters<T>

        Returns ReturnType<T> | undefined

      • <T extends (this: void) => unknown>(fn: T): ReturnType<T> | undefined
      • Type Parameters

        • T extends (this: void) => unknown

        Parameters

        • fn: T

        Returns ReturnType<T> | undefined

    The function to invoke.

    this value to invoke fn with (optional for context-free functions).

    Arguments to invoke fn with (optional for context-free functions).

    The result of fn, or undefined if it threw.