{"ast":null,"code":"\"use strict\";\n\n//\n// Copyright (c) Microsoft. All rights reserved.\n// Licensed under the MIT license. See LICENSE.md file in the project root for full license information.\n//\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\nexports.Diagnostics = void 0;\nconst Exports_js_1 = require(\"../common.browser/Exports.js\");\nconst Exports_js_2 = require(\"../common/Exports.js\");\n/**\n * Defines diagnostics API for managing console output\n * Added in version 1.21.0\n */\nclass Diagnostics {\n static SetLoggingLevel(logLevel) {\n this.privListener = new Exports_js_1.ConsoleLoggingListener(logLevel);\n Exports_js_2.Events.instance.attachConsoleListener(this.privListener);\n }\n static StartConsoleOutput() {\n if (!!this.privListener) {\n this.privListener.enableConsoleOutput = true;\n }\n }\n static StopConsoleOutput() {\n if (!!this.privListener) {\n this.privListener.enableConsoleOutput = false;\n }\n }\n static SetLogOutputPath(path) {\n if (typeof window === \"undefined\") {\n if (!!this.privListener) {\n this.privListener.logPath = path;\n }\n } else {\n throw new Error(\"File system logging not available in browser.\");\n }\n }\n static set onLogOutput(callback) {\n if (!!this.privListener) {\n this.privListener.logCallback = callback;\n }\n }\n}\nexports.Diagnostics = Diagnostics;\nDiagnostics.privListener = undefined;","map":{"version":3,"names":["Object","defineProperty","exports","value","Diagnostics","Exports_js_1","require","Exports_js_2","SetLoggingLevel","logLevel","privListener","ConsoleLoggingListener","Events","instance","attachConsoleListener","StartConsoleOutput","enableConsoleOutput","StopConsoleOutput","SetLogOutputPath","path","window","logPath","Error","onLogOutput","callback","logCallback","undefined"],"sources":["F:/workspace/202226701027/huinongbao-app/node_modules/microsoft-cognitiveservices-speech-sdk/distrib/lib/src/sdk/Diagnostics.js"],"sourcesContent":["\"use strict\";\n//\n// Copyright (c) Microsoft. All rights reserved.\n// Licensed under the MIT license. See LICENSE.md file in the project root for full license information.\n//\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.Diagnostics = void 0;\nconst Exports_js_1 = require(\"../common.browser/Exports.js\");\nconst Exports_js_2 = require(\"../common/Exports.js\");\n/**\n * Defines diagnostics API for managing console output\n * Added in version 1.21.0\n */\nclass Diagnostics {\n static SetLoggingLevel(logLevel) {\n this.privListener = new Exports_js_1.ConsoleLoggingListener(logLevel);\n Exports_js_2.Events.instance.attachConsoleListener(this.privListener);\n }\n static StartConsoleOutput() {\n if (!!this.privListener) {\n this.privListener.enableConsoleOutput = true;\n }\n }\n static StopConsoleOutput() {\n if (!!this.privListener) {\n this.privListener.enableConsoleOutput = false;\n }\n }\n static SetLogOutputPath(path) {\n if (typeof window === \"undefined\") {\n if (!!this.privListener) {\n this.privListener.logPath = path;\n }\n }\n else {\n throw new Error(\"File system logging not available in browser.\");\n }\n }\n static set onLogOutput(callback) {\n if (!!this.privListener) {\n this.privListener.logCallback = callback;\n }\n }\n}\nexports.Diagnostics = Diagnostics;\nDiagnostics.privListener = undefined;\n\n"],"mappings":"AAAA,YAAY;;AACZ;AACA;AACA;AACA;AACAA,MAAM,CAACC,cAAc,CAACC,OAAO,EAAE,YAAY,EAAE;EAAEC,KAAK,EAAE;AAAK,CAAC,CAAC;AAC7DD,OAAO,CAACE,WAAW,GAAG,KAAK,CAAC;AAC5B,MAAMC,YAAY,GAAGC,OAAO,CAAC,8BAA8B,CAAC;AAC5D,MAAMC,YAAY,GAAGD,OAAO,CAAC,sBAAsB,CAAC;AACpD;AACA;AACA;AACA;AACA,MAAMF,WAAW,CAAC;EACd,OAAOI,eAAeA,CAACC,QAAQ,EAAE;IAC7B,IAAI,CAACC,YAAY,GAAG,IAAIL,YAAY,CAACM,sBAAsB,CAACF,QAAQ,CAAC;IACrEF,YAAY,CAACK,MAAM,CAACC,QAAQ,CAACC,qBAAqB,CAAC,IAAI,CAACJ,YAAY,CAAC;EACzE;EACA,OAAOK,kBAAkBA,CAAA,EAAG;IACxB,IAAI,CAAC,CAAC,IAAI,CAACL,YAAY,EAAE;MACrB,IAAI,CAACA,YAAY,CAACM,mBAAmB,GAAG,IAAI;IAChD;EACJ;EACA,OAAOC,iBAAiBA,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