docs: complete XML doc coverage (returns, summaries, inheritdoc)

Resolve all 622 issues flagged by the enhanced CommentChecker: add missing
<returns> tags (incl. the standard phrasing on non-generic Task methods),
add missing <summary> tags, and replace misused/redundant <inheritdoc/> on
members that override or implement nothing with real documentation.
Documentation-only — no behavior change; solution builds clean.
This commit is contained in:
Joseph Doherty
2026-06-03 11:39:32 -04:00
parent a050170414
commit eabf270d71
208 changed files with 867 additions and 114 deletions
@@ -33,6 +33,16 @@ public static class CredentialRedactor
/// </summary>
private const int MinSecretLength = 12;
/// <summary>
/// Returns <paramref name="text"/> with every secret component of the supplied
/// colon-delimited credential string masked.
/// </summary>
/// <param name="text">The text to scrub (e.g. an exception message). Returns empty string if null.</param>
/// <param name="credentials">
/// The credential string in use — Basic Auth <c>user:pass</c> or OAuth2
/// <c>tenantId:clientId:clientSecret</c>. May be null; returns <paramref name="text"/> unmodified when null.
/// </param>
/// <returns>The scrubbed text with secret components replaced by <c>***REDACTED***</c>.</returns>
public static string Scrub(string? text, string? credentials)
{
if (string.IsNullOrEmpty(text) || string.IsNullOrEmpty(credentials))
@@ -20,6 +20,7 @@ public static class EmailAddressValidator
/// </summary>
/// <param name="fromAddress">The sender email address to validate.</param>
/// <param name="recipients">The list of recipient addresses to validate.</param>
/// <returns>A human-readable error string if any address is malformed; <c>null</c> if all addresses parse successfully.</returns>
public static string? ValidateAddresses(
string fromAddress, IReadOnlyList<NotificationRecipient> recipients)
{
@@ -20,6 +20,7 @@ public interface ISmtpClientWrapper
/// <param name="host">SMTP server hostname or IP address.</param>
/// <param name="port">SMTP server port.</param>
/// <param name="cancellationToken">Cancellation token.</param>
/// <returns>A task that represents the asynchronous operation.</returns>
Task ConnectAsync(
string host,
int port,
@@ -37,6 +38,7 @@ public interface ISmtpClientWrapper
/// callers that do not authenticate with OAuth2.
/// </param>
/// <param name="cancellationToken">Cancellation token.</param>
/// <returns>A task that represents the asynchronous operation.</returns>
Task AuthenticateAsync(
string authType,
string? credentials,
@@ -48,8 +50,10 @@ public interface ISmtpClientWrapper
/// <param name="subject">Email subject line.</param>
/// <param name="body">Plain-text email body.</param>
/// <param name="cancellationToken">Cancellation token.</param>
/// <returns>A task that represents the asynchronous operation.</returns>
Task SendAsync(string from, IEnumerable<string> bccRecipients, string subject, string body, CancellationToken cancellationToken = default);
/// <summary>Disconnects from the SMTP server gracefully.</summary>
/// <param name="cancellationToken">Cancellation token.</param>
/// <returns>A task that represents the asynchronous operation.</returns>
Task DisconnectAsync(CancellationToken cancellationToken = default);
}
@@ -14,6 +14,7 @@ public static class ServiceCollectionExtensions
/// was removed (NS-019). Notification dispatch lives in <c>ZB.MOM.WW.ScadaBridge.NotificationOutbox</c>.
/// </summary>
/// <param name="services">The service collection to register into.</param>
/// <returns>The same <paramref name="services"/> collection, for chaining.</returns>
public static IServiceCollection AddNotificationService(this IServiceCollection services)
{
services.AddOptions<NotificationOptions>()
@@ -30,6 +31,7 @@ public static class ServiceCollectionExtensions
/// Registers Akka.NET actors for the notification service (placeholder for actor registration).
/// </summary>
/// <param name="services">The service collection to register into.</param>
/// <returns>The same <paramref name="services"/> collection, for chaining.</returns>
public static IServiceCollection AddNotificationServiceActors(this IServiceCollection services)
{
// Actor registration happens in AkkaHostedService.
@@ -43,6 +43,7 @@ public static class SmtpErrorClassifier
/// The token governing the send; a requested cancellation classifies as
/// <see cref="SmtpErrorClass.Unknown"/> so the caller can re-throw it.
/// </param>
/// <returns>The <see cref="SmtpErrorClass"/> describing whether the failure is transient, permanent, or unknown.</returns>
public static SmtpErrorClass Classify(Exception ex, CancellationToken cancellationToken)
{
ArgumentNullException.ThrowIfNull(ex);
@@ -90,6 +91,7 @@ public static class SmtpErrorClassifier
/// </summary>
/// <param name="ex">The exception to classify.</param>
/// <param name="cancellationToken">Cancellation token passed to <see cref="Classify"/>.</param>
/// <returns><c>true</c> when <see cref="Classify"/> returns <see cref="SmtpErrorClass.Transient"/>.</returns>
public static bool IsTransient(Exception ex, CancellationToken cancellationToken)
=> Classify(ex, cancellationToken) == SmtpErrorClass.Transient;
}
@@ -30,6 +30,7 @@ public static class SmtpTlsModeParser
/// </summary>
/// <param name="tlsMode">The TLS mode string to parse (None, StartTLS, or SSL); null/empty defaults to StartTLS.</param>
/// <exception cref="ArgumentException">The value is not one of None/StartTLS/SSL.</exception>
/// <returns>The corresponding <see cref="SmtpTlsMode"/> enum value.</returns>
public static SmtpTlsMode Parse(string? tlsMode)
{
if (string.IsNullOrWhiteSpace(tlsMode))