UNPKG

@microsoft/teams-js

Version:

Microsoft Client SDK for building app for Microsoft hosts

52 lines (51 loc) 2.04 kB
import { Debugger } from 'debug'; import { UUID as MessageUUID } from '../public/uuidObject'; import { CallbackInformation } from './interfaces'; import { MessageRequest, MessageResponse } from './messageObjects'; /** * @internal * Limited to Microsoft-internal use */ export default class HostToAppMessageDelayTelemetry { private static callbackInformation; /** * @internal * Limited to Microsoft-internal use * * Store information about a particular message. * @param messageUUID The message id for the request. * @param callbackInformation The information of the callback. */ static storeCallbackInformation(messageUUID: MessageUUID, callbackInformation: CallbackInformation): void; /** * @internal * Limited to Microsoft-internal use */ static clearMessages(): void; /** * @internal * Limited to Microsoft-internal use */ static deleteMessageInformation(callbackId: MessageUUID): void; /** * @internal * Limited to Microsoft-internal use * * Executes telemetry actions related to host to app performance metrics where event is raised in the host. * @param message The request from the host. * @param logger The logger in case an error occurs. * @param endTime The ending time for calculating the elapsed time */ static handleOneWayPerformanceMetrics(message: MessageRequest, logger: Debugger, endTime?: number): void; /** * @internal * Limited to Microsoft-internal use * * Executes telemetry actions related to host to app performance metrics. * @param callbackId The message id for the request. * @param message The response from the host. * @param logger The logger in case an error occurs. * @param endTime The ending time for calculating the elapsed time */ static handlePerformanceMetrics(callbackID: MessageUUID, message: MessageResponse, logger: Debugger, endTime?: number): void; }