Skip to main content

TelemetryEvent

Represents a telemetry event that can be use to track events.

Index

Constructors

Properties

Methods

Constructors

publicconstructor

  • new TelemetryEvent(name: string, _client: TwinfinityTelemetryClient): TelemetryEvent
  • Creates a new instance of TelemetryEvent.


    Parameters

    • name: string

      The name of the telemetry event.

    • _client: TwinfinityTelemetryClient

      The telemetry client used to track the event.

    Returns TelemetryEvent

Properties

publicreadonlyname

name: string

The name of the telemetry event.

Methods

publicstop

  • stop(customProperties?: ICustomProperties): void
  • Stops the telemetry event and tracks it with the specified custom properties. Also adds a duration in ms to the logged event properties.


    Parameters

    • optionalcustomProperties: ICustomProperties

      Optional custom properties to be associated with the event.

    Returns void