Restructure solution layout by module
This commit is contained in:
@@ -0,0 +1,23 @@
|
||||
namespace StellaOps.Notify.Models;
|
||||
|
||||
/// <summary>
|
||||
/// Canonical schema version identifiers for Notify documents.
|
||||
/// </summary>
|
||||
public static class NotifySchemaVersions
|
||||
{
|
||||
public const string Rule = "notify.rule@1";
|
||||
public const string Channel = "notify.channel@1";
|
||||
public const string Template = "notify.template@1";
|
||||
|
||||
public static string EnsureRule(string? value)
|
||||
=> Normalize(value, Rule);
|
||||
|
||||
public static string EnsureChannel(string? value)
|
||||
=> Normalize(value, Channel);
|
||||
|
||||
public static string EnsureTemplate(string? value)
|
||||
=> Normalize(value, Template);
|
||||
|
||||
private static string Normalize(string? value, string fallback)
|
||||
=> string.IsNullOrWhiteSpace(value) ? fallback : value.Trim();
|
||||
}
|
||||
Reference in New Issue
Block a user