Constructors

Properties

#inner: InternalRateMetricType

Methods

  • Increases the denominator by amount.

    Note

    Records an InvalidValue error if the amount is negative.

    Parameters

    • amount: number

      The amount to increase by. Should be non-negative.

    Returns void

  • Increases the numerator by amount.

    Note

    Records an InvalidValue error if the amount is negative.

    Parameters

    • amount: number

      The amount to increase by. Should be non-negative.

    Returns void

  • Test-only API

    Returns the number of errors recorded for the given metric.

    Parameters

    • errorType: string

      The type of the error recorded.

    • ping: string = ...

      represents the name of the ping to retrieve the metric for. Defaults to the first value in sendInPings.

    Returns number

    the number of errors recorded for the metric.

  • Test-only API.**

    Gets the currently stored value as an object.

    Note

    This function will return the Rate for convenience.

    This doesn't clear the stored value.

    Parameters

    • ping: string = ...

      the ping from which we want to retrieve this metrics value from. Defaults to the first value in sendInPings.

    Returns undefined | Rate

    The value found in storage or undefined if nothing was found.

Generated using TypeDoc