LogCallback Delegate
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Callback delegate that allows application developers to consume logs, and handle them in a custom manner. This
callback is set using WithLogging(LogCallback, Nullable<LogLevel>, Nullable<Boolean>, Nullable<Boolean>).
If PiiLoggingEnabled
is set to true
, when registering the callback this method will receive the messages twice:
once with the containsPii
parameter equals false
and the message without PII,
and a second time with the containsPii
parameter equals to true
and the message might contain PII.
In some cases (when the message does not contain PII), the message will be the same.
For details see https://aka.ms/msal-net-logging
public delegate void LogCallback(LogLevel level, string message, bool containsPii);
type LogCallback = delegate of LogLevel * string * bool -> unit
Public Delegate Sub LogCallback(level As LogLevel, message As String, containsPii As Boolean)
Parameters
- level
- LogLevel
Log level of the log message to process
- message
- String
Pre-formatted log message
- containsPii
- Boolean
Indicates if the log message contains Organizational Identifiable Information (OII)
or Personally Identifiable Information (PII) nor not.
If PiiLoggingEnabled is set to false
then this value is always false.
Otherwise it will be true
when the message contains PII.
Applies to
See also
意見反應
https://aka.ms/ContentUserFeedback。
即將登場:在 2024 年,我們將逐步淘汰 GitHub 問題作為內容的意見反應機制,並將它取代為新的意見反應系統。 如需詳細資訊,請參閱:提交並檢視相關的意見反應