Interface ILog
Provides access to log entries.
public interface ILog
Properties
EntryAdded
Issued when new message was logged.
IEventSource<EntryAddedEventArgs> EntryAdded { get; }
Property Value
- IEventSource<EntryAddedEventArgs>
Remarks
Event args (EntryAddedEventArgs):
- Entry - The entry.
Methods
ClearAsync(string?, CancellationToken)
Clears the log.
Task<ClearResult> ClearAsync(string? session = null, CancellationToken cancellationToken = default)
Parameters
sessionstringOptional CDP session override.
cancellationTokenCancellationTokenA token to cancel the asynchronous operation.
Returns
- Task<ClearResult>
A task representing the asynchronous operation, containing a ClearResult.
DisableAsync(string?, CancellationToken)
Disables log domain, prevents further log entries from being reported to the client.
Task<DisableResult> DisableAsync(string? session = null, CancellationToken cancellationToken = default)
Parameters
sessionstringOptional CDP session override.
cancellationTokenCancellationTokenA token to cancel the asynchronous operation.
Returns
- Task<DisableResult>
A task representing the asynchronous operation, containing a DisableResult.
EnableAsync(string?, CancellationToken)
Enables log domain, sends the entries collected so far to the client by means of the entryAdded notification.
Task<EnableResult> EnableAsync(string? session = null, CancellationToken cancellationToken = default)
Parameters
sessionstringOptional CDP session override.
cancellationTokenCancellationTokenA token to cancel the asynchronous operation.
Returns
- Task<EnableResult>
A task representing the asynchronous operation, containing a EnableResult.
StartViolationsReportAsync(ImmutableArray<ViolationSetting>, string?, CancellationToken)
start violation reporting.
Task<StartViolationsReportResult> StartViolationsReportAsync(ImmutableArray<ViolationSetting> config, string? session = null, CancellationToken cancellationToken = default)
Parameters
configImmutableArray<ViolationSetting>Configuration for violations.
sessionstringOptional CDP session override.
cancellationTokenCancellationTokenA token to cancel the asynchronous operation.
Returns
- Task<StartViolationsReportResult>
A task representing the asynchronous operation, containing a StartViolationsReportResult.
StopViolationsReportAsync(string?, CancellationToken)
Stop violation reporting.
Task<StopViolationsReportResult> StopViolationsReportAsync(string? session = null, CancellationToken cancellationToken = default)
Parameters
sessionstringOptional CDP session override.
cancellationTokenCancellationTokenA token to cancel the asynchronous operation.
Returns
- Task<StopViolationsReportResult>
A task representing the asynchronous operation, containing a StopViolationsReportResult.