UNPKG

@voice-ping/cognitive-services-speech

Version:

VoicePing Cognitive Services Speech SDK for JavaScript forked from Microsoft

1 lines 2.85 kB
{"version":3,"sources":["src/sdk/Transcription/ConversationTranslationCanceledEventArgs.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,qBAAqB,EAAE,kBAAkB,EAAE,oBAAoB,EAAE,MAAM,YAAY,CAAC;AAE7F,qBAAa,wCAAyC,SAAQ,oBAAoB;IAC9E,OAAO,CAAC,UAAU,CAAqB;IACvC,OAAO,CAAC,gBAAgB,CAAS;IACjC,OAAO,CAAC,aAAa,CAAwB;IAE7C;;;;;;;OAOG;gBACgB,MAAM,EAAE,kBAAkB,EAC1B,YAAY,EAAE,MAAM,EACpB,SAAS,EAAE,qBAAqB,EAChC,MAAM,CAAC,EAAE,MAAM,EACf,SAAS,CAAC,EAAE,MAAM;IAQrC;;;;;;OAMG;IACH,IAAW,MAAM,IAAI,kBAAkB,CAEtC;IAED;;;;OAIG;IACH,IAAW,SAAS,IAAI,qBAAqB,CAE5C;IAED;;;;;;OAMG;IACH,IAAW,YAAY,IAAI,MAAM,CAEhC;CACJ","file":"ConversationTranslationCanceledEventArgs.d.ts","sourcesContent":["// Copyright (c) Microsoft Corporation. All rights reserved.\n// Licensed under the MIT license.\n// Multi-device Conversation is a Preview feature.\n\nimport { CancellationErrorCode, CancellationReason, RecognitionEventArgs } from \"../Exports\";\n\nexport class ConversationTranslationCanceledEventArgs extends RecognitionEventArgs {\n private privReason: CancellationReason;\n private privErrorDetails: string;\n private privErrorCode: CancellationErrorCode;\n\n /**\n * Creates and initializes an instance of this class.\n * @constructor\n * @param {CancellationReason} reason - The cancellation reason.\n * @param {string} errorDetails - Error details, if provided.\n * @param {number} offset - The offset.\n * @param {string} sessionId - The session id.\n */\n public constructor(reason: CancellationReason,\n errorDetails: string,\n errorCode: CancellationErrorCode,\n offset?: number,\n sessionId?: string) {\n super(offset, sessionId);\n\n this.privReason = reason;\n this.privErrorDetails = errorDetails;\n this.privErrorCode = errorCode;\n }\n\n /**\n * The reason the recognition was canceled.\n * @member SpeechRecognitionCanceledEventArgs.prototype.reason\n * @function\n * @public\n * @returns {CancellationReason} Specifies the reason canceled.\n */\n public get reason(): CancellationReason {\n return this.privReason;\n }\n\n /**\n * The error code in case of an unsuccessful recognition.\n * Added in version 1.1.0.\n * @return An error code that represents the error reason.\n */\n public get errorCode(): CancellationErrorCode {\n return this.privErrorCode;\n }\n\n /**\n * In case of an unsuccessful recognition, provides details of the occurred error.\n * @member SpeechRecognitionCanceledEventArgs.prototype.errorDetails\n * @function\n * @public\n * @returns {string} A String that represents the error details.\n */\n public get errorDetails(): string {\n return this.privErrorDetails;\n }\n}\n"]}