Megosztás a következőn keresztül:


FileLogger Class

Definition

A static class to control file-based SDK logging. Turning on logging while running your Speech SDK scenario provides detailed information from the SDK's core native components. If you report an issue to Microsoft, you may be asked to provide logs to help Microsoft diagnose the issue. Your application should not take dependency on particular log strings, as they may change from one SDK release to another without notice. FileLogger is the simplest logging solution and suitable for diagnosing most on-device issues when running Speech SDK. Added in version 1.20.0

public static class FileLogger
type FileLogger = class
Public Class FileLogger
Inheritance
FileLogger

Remarks

File logging is a process wide construct. That means that if (for example) you have multiple speech recognizer objects running in parallel, there will be one log file containing interleaved logs lines from all recognizers. You cannot get a separate log file for each recognizer.

Methods

SetFilters(String[])

Sets or clears the filters that apply to file logging. Once filters are set, the event will be invoked only if the log string contains at least one of the strings specified by the filters. The match is case sensitive.

SetLevel(Level)

Sets the level of the messages to be captured by the logger

Start(String, Boolean)

Starts logging to a file.

Stop()

Stops logging to a file.

Applies to