| | | 1 | | // ----------------------------------------------------------------------- |
| | | 2 | | // <copyright file="MetadataProviderGenerator.cs" company="Stéphane ANDRE"> |
| | | 3 | | // Copyright (c) Stéphane ANDRE. All rights reserved. |
| | | 4 | | // </copyright> |
| | | 5 | | // ----------------------------------------------------------------------- |
| | | 6 | | |
| | | 7 | | using System; |
| | | 8 | | using System.Collections.Generic; |
| | | 9 | | using System.Collections.Immutable; |
| | | 10 | | using System.Diagnostics.CodeAnalysis; |
| | | 11 | | using System.Linq; |
| | | 12 | | using System.Text; |
| | | 13 | | using Microsoft.CodeAnalysis; |
| | | 14 | | using Microsoft.CodeAnalysis.CSharp.Syntax; |
| | | 15 | | using Microsoft.CodeAnalysis.Text; |
| | | 16 | | |
| | | 17 | | namespace MyNet.Observable.Metadata.Generator; |
| | | 18 | | |
| | | 19 | | [Generator(LanguageNames.CSharp)] |
| | | 20 | | public sealed class MetadataProviderGenerator : IIncrementalGenerator |
| | | 21 | | { |
| | | 22 | | private const string IgnoreModificationTrackingAttribute = "MyNet.Observable.Behaviors.Metadata.Attributes.IgnoreMod |
| | | 23 | | private const string UpdateOnCultureChangedAttribute = "MyNet.Observable.Behaviors.Metadata.Attributes.UpdateOnCultu |
| | | 24 | | private const string UpdateOnTimeZoneChangedAttribute = "MyNet.Observable.Behaviors.Metadata.Attributes.UpdateOnTime |
| | | 25 | | private const string AlsoValidateAttribute = "MyNet.Observable.Behaviors.Metadata.Attributes.AlsoValidateAttribute"; |
| | | 26 | | |
| | | 27 | | // Behavior-related property attributes |
| | | 28 | | private const string ForwardPropertyAttribute = "MyNet.Observable.Behaviors.Metadata.Attributes.ForwardPropertyAttri |
| | | 29 | | private const string EnforceGeneratedMetadataAttribute = "MyNet.Observable.Metadata.EnforceGeneratedMetadataAttribut |
| | | 30 | | private const string ExemptFromGeneratedMetadataAttribute = "MyNet.Observable.Metadata.ExemptFromGeneratedMetadataAt |
| | | 31 | | private const string ObservableObjectType = "MyNet.Observable.ObservableObject"; |
| | | 32 | | |
| | 3 | 33 | | private static readonly DiagnosticDescriptor MissingProviderDescriptor = new( |
| | 3 | 34 | | id: "MNETMETA001", |
| | 3 | 35 | | title: "Generated metadata configuration is missing", |
| | 3 | 36 | | messageFormat: "Type '{0}' derives from ObservableObject but has no generated metadata configuration. Add metada |
| | 3 | 37 | | category: "MyNet.Observable.Metadata.Generator", |
| | 3 | 38 | | defaultSeverity: DiagnosticSeverity.Error, |
| | 3 | 39 | | isEnabledByDefault: true); |
| | | 40 | | |
| | | 41 | | public void Initialize(IncrementalGeneratorInitializationContext context) |
| | | 42 | | { |
| | | 43 | | // Check for strict mode assembly attribute |
| | 27 | 44 | | var enforceMetadata = context.CompilationProvider |
| | 27 | 45 | | .Select(static (compilation, _) => HasEnforceGeneratedMetadataAttribute(compilation)); |
| | | 46 | | |
| | 27 | 47 | | var candidates = context.SyntaxProvider |
| | 27 | 48 | | .CreateSyntaxProvider( |
| | 27 | 49 | | static (node, _) => node is ClassDeclarationSyntax, |
| | 27 | 50 | | static (ctx, _) => GetTypeModel(ctx)) |
| | 27 | 51 | | .Where(static model => model is not null) |
| | 27 | 52 | | .Select(static (model, _) => model!); |
| | | 53 | | |
| | 27 | 54 | | context.RegisterSourceOutput( |
| | 27 | 55 | | candidates.Collect().Combine(enforceMetadata).Combine(context.CompilationProvider), |
| | 27 | 56 | | static (spc, data) => Emit(spc, data.Left.Left, data.Left.Right, data.Right)); |
| | 27 | 57 | | } |
| | | 58 | | |
| | | 59 | | private static bool HasEnforceGeneratedMetadataAttribute(Compilation compilation) |
| | 27 | 60 | | => compilation.Assembly.GetAttributes() |
| | 27 | 61 | | .Any(attr => attr.AttributeClass?.ToDisplayString() == EnforceGeneratedMetadataAttribute); |
| | | 62 | | |
| | | 63 | | private static TypeModel? GetTypeModel(GeneratorSyntaxContext context) |
| | | 64 | | { |
| | 33 | 65 | | if (context.Node is not ClassDeclarationSyntax classSyntax) |
| | 0 | 66 | | return null; |
| | | 67 | | |
| | 33 | 68 | | if (context.SemanticModel.GetDeclaredSymbol(classSyntax) is not INamedTypeSymbol typeSymbol) |
| | 0 | 69 | | return null; |
| | | 70 | | |
| | 33 | 71 | | var observableObjectSymbol = context.SemanticModel.Compilation.GetTypeByMetadataName(ObservableObjectType); |
| | 33 | 72 | | if (observableObjectSymbol is null || !InheritsFrom(typeSymbol, observableObjectSymbol)) |
| | 6 | 73 | | return null; |
| | | 74 | | |
| | 27 | 75 | | var properties = |
| | 27 | 76 | | (from property in typeSymbol.GetMembers().OfType<IPropertySymbol>() |
| | 27 | 77 | | where !property.IsStatic |
| | 27 | 78 | | let model = BuildPropertyModel(property) |
| | 27 | 79 | | where model is not null |
| | 27 | 80 | | select model) |
| | 27 | 81 | | .ToImmutableArray(); |
| | | 82 | | |
| | 27 | 83 | | if (properties.Length == 0) |
| | 9 | 84 | | return null; |
| | | 85 | | |
| | 18 | 86 | | var fullyQualifiedTypeName = typeSymbol.ToDisplayString(SymbolDisplayFormat.FullyQualifiedFormat); |
| | | 87 | | |
| | 18 | 88 | | return new TypeModel(fullyQualifiedTypeName, properties); |
| | | 89 | | } |
| | | 90 | | |
| | | 91 | | [SuppressMessage("ReSharper", "MergeIntoPattern", Justification = "Improves readability in this case")] |
| | | 92 | | private static PropertyModel? BuildPropertyModel(IPropertySymbol property) |
| | | 93 | | { |
| | 21 | 94 | | var ignoreTracking = false; |
| | 21 | 95 | | var reactsToCulture = false; |
| | 21 | 96 | | var reactsToTimeZone = false; |
| | 21 | 97 | | var propertyChangedForwarding = false; |
| | 21 | 98 | | var concatenateForwardedPropertyName = true; |
| | 21 | 99 | | var validationDependents = ImmutableArray<string>.Empty; |
| | | 100 | | |
| | 42 | 101 | | foreach (var attributeName in from attribute in property.GetAttributes() let attributeName = attribute.Attribute |
| | | 102 | | { |
| | | 103 | | switch (attributeName) |
| | | 104 | | { |
| | | 105 | | default: |
| | | 106 | | continue; |
| | | 107 | | } |
| | | 108 | | } |
| | | 109 | | |
| | 21 | 110 | | return !ignoreTracking && !reactsToCulture && !reactsToTimeZone && !propertyChangedForwarding && validationDepen |
| | 21 | 111 | | ? null |
| | 21 | 112 | | : new PropertyModel(property.Name, ignoreTracking, reactsToCulture, reactsToTimeZone, propertyChangedForward |
| | | 113 | | } |
| | | 114 | | |
| | | 115 | | [SuppressMessage("ReSharper", "MergeIntoPattern", Justification = "Improves readability in this case")] |
| | | 116 | | private static bool TryApplyFeatureAttribute( |
| | | 117 | | string? attributeName, |
| | | 118 | | AttributeData attribute, |
| | | 119 | | ref bool ignoreTracking, |
| | | 120 | | ref bool reactsToCulture, |
| | | 121 | | ref bool reactsToTimeZone, |
| | | 122 | | ref ImmutableArray<string> validationDependents) |
| | | 123 | | { |
| | | 124 | | switch (attributeName) |
| | | 125 | | { |
| | | 126 | | case IgnoreModificationTrackingAttribute: |
| | 3 | 127 | | ignoreTracking = true; |
| | 3 | 128 | | return true; |
| | | 129 | | case UpdateOnCultureChangedAttribute: |
| | 12 | 130 | | reactsToCulture = true; |
| | 12 | 131 | | return true; |
| | | 132 | | case UpdateOnTimeZoneChangedAttribute: |
| | 0 | 133 | | reactsToTimeZone = true; |
| | 0 | 134 | | return true; |
| | | 135 | | case AlsoValidateAttribute: |
| | 0 | 136 | | if (attribute.ConstructorArguments.Length == 1 && |
| | 0 | 137 | | attribute.ConstructorArguments[0].Value is string dependent && |
| | 0 | 138 | | !string.IsNullOrWhiteSpace(dependent)) |
| | | 139 | | { |
| | 0 | 140 | | validationDependents = validationDependents.Add(dependent); |
| | | 141 | | } |
| | | 142 | | |
| | 0 | 143 | | return true; |
| | | 144 | | default: |
| | 6 | 145 | | return false; |
| | | 146 | | } |
| | | 147 | | } |
| | | 148 | | |
| | | 149 | | private static bool TryApplyBehaviorAttribute(string? attributeName, AttributeData attribute, ref bool propertyChang |
| | | 150 | | { |
| | | 151 | | switch (attributeName) |
| | | 152 | | { |
| | | 153 | | case ForwardPropertyAttribute: |
| | 6 | 154 | | propertyChangedForwarding = true; |
| | | 155 | | |
| | 6 | 156 | | if (attribute.ConstructorArguments.Length > 0 && attribute.ConstructorArguments[0].Value is bool ctorVal |
| | 0 | 157 | | concatenateForwardedPropertyName = ctorValue; |
| | | 158 | | |
| | 12 | 159 | | foreach (var namedArgument in attribute.NamedArguments) |
| | | 160 | | { |
| | 0 | 161 | | if (!string.Equals(namedArgument.Key, "ConcatenatePropertyName", StringComparison.Ordinal) || |
| | 0 | 162 | | namedArgument.Value.Value is not bool namedValue) |
| | | 163 | | { |
| | | 164 | | continue; |
| | | 165 | | } |
| | | 166 | | |
| | 0 | 167 | | concatenateForwardedPropertyName = namedValue; |
| | 0 | 168 | | break; |
| | | 169 | | } |
| | | 170 | | |
| | 6 | 171 | | return true; |
| | | 172 | | default: |
| | 0 | 173 | | return false; |
| | | 174 | | } |
| | | 175 | | } |
| | | 176 | | |
| | | 177 | | private static void Emit(SourceProductionContext context, ImmutableArray<TypeModel> models, bool enforceGeneratedMet |
| | | 178 | | { |
| | 27 | 179 | | var distinctModels = models |
| | 27 | 180 | | .GroupBy(static x => x.FullyQualifiedTypeName, StringComparer.Ordinal) |
| | 27 | 181 | | .Select(static x => x.First()) |
| | 27 | 182 | | .OrderBy(static x => x.FullyQualifiedTypeName, StringComparer.Ordinal) |
| | 27 | 183 | | .ToArray(); |
| | | 184 | | |
| | 27 | 185 | | var source = new StringBuilder(); |
| | 27 | 186 | | source.AppendLine("// <auto-generated />"); |
| | 27 | 187 | | source.AppendLine("#nullable enable"); |
| | 27 | 188 | | source.AppendLine("using System;"); |
| | 27 | 189 | | source.AppendLine("using System.Collections.Concurrent;"); |
| | 27 | 190 | | source.AppendLine("using MyNet.Observable.Behaviors.Metadata;"); |
| | 27 | 191 | | source.AppendLine("using MyNet.Metadata;"); |
| | 27 | 192 | | source.AppendLine(); |
| | 27 | 193 | | source.AppendLine("namespace MyNet.Metadata.Generated"); |
| | 27 | 194 | | source.AppendLine("{"); |
| | | 195 | | |
| | | 196 | | // Generate fluent metadata configuration class |
| | 27 | 197 | | if (distinctModels.Length > 0) |
| | | 198 | | { |
| | 18 | 199 | | EmitMetadataBootstrap(source, distinctModels); |
| | | 200 | | } |
| | | 201 | | |
| | 27 | 202 | | source.AppendLine("}"); |
| | | 203 | | |
| | 27 | 204 | | context.AddSource("GeneratedMetadataProviders.g.cs", SourceText.From(source.ToString(), Encoding.UTF8)); |
| | | 205 | | |
| | 27 | 206 | | if (enforceGeneratedMetadata) |
| | 6 | 207 | | ReportMissingMetadata(context, compilation, distinctModels); |
| | 27 | 208 | | } |
| | | 209 | | |
| | | 210 | | private static void ReportMissingMetadata(SourceProductionContext context, Compilation compilation, TypeModel[] gene |
| | | 211 | | { |
| | 6 | 212 | | var observableObjectSymbol = compilation.GetTypeByMetadataName(ObservableObjectType); |
| | 6 | 213 | | if (observableObjectSymbol is null) |
| | 0 | 214 | | return; |
| | | 215 | | |
| | 6 | 216 | | var generatedTypeNames = new HashSet<string>( |
| | 6 | 217 | | generatedModels.Select(x => x.FullyQualifiedTypeName), |
| | 6 | 218 | | StringComparer.Ordinal); |
| | | 219 | | |
| | 30 | 220 | | foreach (var type in EnumerateNamedTypes(compilation.Assembly.GlobalNamespace)) |
| | | 221 | | { |
| | 9 | 222 | | if (type.TypeKind != TypeKind.Class || type.IsAbstract) |
| | | 223 | | continue; |
| | | 224 | | |
| | 9 | 225 | | if (!InheritsFrom(type, observableObjectSymbol)) |
| | | 226 | | continue; |
| | | 227 | | |
| | 6 | 228 | | if (type.GetAttributes().Any(attr => attr.AttributeClass?.ToDisplayString() == ExemptFromGeneratedMetadataAt |
| | | 229 | | continue; |
| | | 230 | | |
| | 3 | 231 | | var typeName = type.ToDisplayString(SymbolDisplayFormat.FullyQualifiedFormat); |
| | 3 | 232 | | if (generatedTypeNames.Contains(typeName)) |
| | | 233 | | continue; |
| | | 234 | | |
| | 3 | 235 | | var location = type.Locations.FirstOrDefault(static l => l.IsInSource); |
| | 3 | 236 | | if (location is null) |
| | | 237 | | continue; |
| | | 238 | | |
| | 3 | 239 | | context.ReportDiagnostic(Diagnostic.Create(MissingProviderDescriptor, location, type.ToDisplayString())); |
| | | 240 | | } |
| | 6 | 241 | | } |
| | | 242 | | |
| | | 243 | | private static bool InheritsFrom(INamedTypeSymbol type, INamedTypeSymbol baseType) |
| | | 244 | | { |
| | 192 | 245 | | for (var current = type; current is not null; current = current.BaseType) |
| | | 246 | | { |
| | 87 | 247 | | if (SymbolEqualityComparer.Default.Equals(current, baseType)) |
| | 33 | 248 | | return true; |
| | | 249 | | } |
| | | 250 | | |
| | 9 | 251 | | return false; |
| | | 252 | | } |
| | | 253 | | |
| | | 254 | | private static IEnumerable<INamedTypeSymbol> EnumerateNamedTypes(INamespaceSymbol ns) |
| | | 255 | | { |
| | 42 | 256 | | foreach (var type in ns.GetTypeMembers()) |
| | | 257 | | { |
| | 9 | 258 | | yield return type; |
| | | 259 | | |
| | 18 | 260 | | foreach (var nested in EnumerateNestedTypes(type)) |
| | 0 | 261 | | yield return nested; |
| | 9 | 262 | | } |
| | | 263 | | |
| | 36 | 264 | | foreach (var child in ns.GetNamespaceMembers()) |
| | | 265 | | { |
| | 30 | 266 | | foreach (var type in EnumerateNamedTypes(child)) |
| | 9 | 267 | | yield return type; |
| | | 268 | | } |
| | 12 | 269 | | } |
| | | 270 | | |
| | | 271 | | private static IEnumerable<INamedTypeSymbol> EnumerateNestedTypes(INamedTypeSymbol type) |
| | | 272 | | { |
| | 18 | 273 | | foreach (var nested in type.GetTypeMembers()) |
| | | 274 | | { |
| | 0 | 275 | | yield return nested; |
| | | 276 | | |
| | 0 | 277 | | foreach (var child in EnumerateNestedTypes(nested)) |
| | 0 | 278 | | yield return child; |
| | 0 | 279 | | } |
| | 9 | 280 | | } |
| | | 281 | | |
| | | 282 | | private static void EmitMetadataBootstrap(StringBuilder source, TypeModel[] distinctModels) |
| | | 283 | | { |
| | 18 | 284 | | source.AppendLine(); |
| | 18 | 285 | | source.AppendLine(" internal static class ObservableMetadataBootstrap"); |
| | 18 | 286 | | source.AppendLine(" {"); |
| | 18 | 287 | | source.AppendLine(" private static readonly ConcurrentDictionary<Type, byte> Applied = new();"); |
| | 18 | 288 | | source.AppendLine(); |
| | 18 | 289 | | source.AppendLine(" internal static void Ensure(Type type)"); |
| | 18 | 290 | | source.AppendLine(" {"); |
| | 18 | 291 | | source.AppendLine(" ArgumentNullException.ThrowIfNull(type);"); |
| | 18 | 292 | | source.AppendLine(); |
| | | 293 | | |
| | 72 | 294 | | foreach (var model in distinctModels) |
| | | 295 | | { |
| | 18 | 296 | | source.Append(" if (type == typeof("); |
| | 18 | 297 | | source.Append(model.FullyQualifiedTypeName); |
| | 18 | 298 | | source.AppendLine("))"); |
| | 18 | 299 | | source.AppendLine(" {"); |
| | 18 | 300 | | source.Append(" EnsureConfigured(type, "); |
| | 18 | 301 | | source.Append(GetConfigureMethodName(model.FullyQualifiedTypeName)); |
| | 18 | 302 | | source.AppendLine(");"); |
| | 18 | 303 | | source.AppendLine(" return;"); |
| | 18 | 304 | | source.AppendLine(" }"); |
| | 18 | 305 | | source.AppendLine(); |
| | | 306 | | } |
| | | 307 | | |
| | 18 | 308 | | source.AppendLine(" }"); |
| | 18 | 309 | | source.AppendLine(); |
| | 18 | 310 | | source.AppendLine(" private static void EnsureConfigured(Type type, Action configure)"); |
| | 18 | 311 | | source.AppendLine(" {"); |
| | 18 | 312 | | source.AppendLine(" if (Applied.TryAdd(type, 0))"); |
| | 18 | 313 | | source.AppendLine(" configure();"); |
| | 18 | 314 | | source.AppendLine(" }"); |
| | 18 | 315 | | source.AppendLine(); |
| | | 316 | | |
| | 72 | 317 | | foreach (var model in distinctModels) |
| | 18 | 318 | | EmitTypeConfigurationMethod(source, model); |
| | | 319 | | |
| | 18 | 320 | | source.AppendLine(" }"); |
| | 18 | 321 | | } |
| | | 322 | | |
| | | 323 | | private static string GetConfigureMethodName(string fullyQualifiedTypeName) |
| | | 324 | | { |
| | 36 | 325 | | var name = fullyQualifiedTypeName |
| | 36 | 326 | | .Replace("global::", string.Empty) |
| | 36 | 327 | | .Replace('.', '_') |
| | 36 | 328 | | .Replace('<', '_') |
| | 36 | 329 | | .Replace('>', '_'); |
| | | 330 | | |
| | 36 | 331 | | return "Configure_" + name; |
| | | 332 | | } |
| | | 333 | | |
| | | 334 | | private static void EmitTypeConfigurationMethod(StringBuilder source, TypeModel model) |
| | | 335 | | { |
| | 18 | 336 | | var methodName = GetConfigureMethodName(model.FullyQualifiedTypeName); |
| | 18 | 337 | | source.Append(" private static void "); |
| | 18 | 338 | | source.Append(methodName); |
| | 18 | 339 | | source.AppendLine("()"); |
| | 18 | 340 | | source.AppendLine(" {"); |
| | | 341 | | |
| | 72 | 342 | | foreach (var property in model.Properties) |
| | | 343 | | { |
| | 18 | 344 | | EmitPropertyConfiguration(source, model, property); |
| | | 345 | | } |
| | | 346 | | |
| | 18 | 347 | | source.AppendLine(" }"); |
| | 18 | 348 | | source.AppendLine(); |
| | 18 | 349 | | } |
| | | 350 | | |
| | | 351 | | private static void EmitPropertyConfiguration(StringBuilder source, TypeModel model, PropertyModel property) |
| | | 352 | | { |
| | 18 | 353 | | source.Append(" var metadata_"); |
| | 18 | 354 | | source.Append(property.Name); |
| | 18 | 355 | | source.Append(" = MetadataRegistry.Get(typeof("); |
| | 18 | 356 | | source.Append(model.FullyQualifiedTypeName); |
| | 18 | 357 | | source.Append(")).GetProperty(\""); |
| | 18 | 358 | | source.Append(property.Name); |
| | 18 | 359 | | source.AppendLine("\");"); |
| | | 360 | | |
| | 18 | 361 | | if (property.IgnoreModificationTracking) |
| | | 362 | | { |
| | 3 | 363 | | source.Append(" MetadataApplicators.ApplyIgnoreModificationTracking(metadata_"); |
| | 3 | 364 | | source.Append(property.Name); |
| | 3 | 365 | | source.AppendLine(");"); |
| | | 366 | | } |
| | | 367 | | |
| | 18 | 368 | | if (property.ReactsToCulture) |
| | | 369 | | { |
| | 12 | 370 | | source.Append(" MetadataApplicators.ApplyUpdateOnCultureChanged(metadata_"); |
| | 12 | 371 | | source.Append(property.Name); |
| | 12 | 372 | | source.AppendLine(");"); |
| | | 373 | | } |
| | | 374 | | |
| | 18 | 375 | | if (property.ReactsToTimeZone) |
| | | 376 | | { |
| | 0 | 377 | | source.Append(" MetadataApplicators.ApplyUpdateOnTimeZoneChanged(metadata_"); |
| | 0 | 378 | | source.Append(property.Name); |
| | 0 | 379 | | source.AppendLine(");"); |
| | | 380 | | } |
| | | 381 | | |
| | 36 | 382 | | foreach (var dependent in property.ValidationDependents) |
| | | 383 | | { |
| | 0 | 384 | | source.Append(" MetadataApplicators.ApplyAlsoValidate(metadata_"); |
| | 0 | 385 | | source.Append(property.Name); |
| | 0 | 386 | | source.Append(", \""); |
| | 0 | 387 | | source.Append(dependent.Replace("\"", "\\\"")); |
| | 0 | 388 | | source.AppendLine("\");"); |
| | | 389 | | } |
| | | 390 | | |
| | 30 | 391 | | if (!property.PropertyChangedForwarding) return; |
| | 6 | 392 | | source.Append(" MetadataApplicators.ApplyForwardProperty(metadata_"); |
| | 6 | 393 | | source.Append(property.Name); |
| | 6 | 394 | | source.Append(", "); |
| | 6 | 395 | | source.Append(property.ConcatenateForwardedPropertyName ? "true" : "false"); |
| | 6 | 396 | | source.AppendLine(");"); |
| | 6 | 397 | | } |
| | | 398 | | |
| | | 399 | | private sealed class TypeModel(string fullyQualifiedTypeName, ImmutableArray<PropertyModel> properties) |
| | | 400 | | { |
| | | 401 | | public string FullyQualifiedTypeName { get; } = fullyQualifiedTypeName; |
| | | 402 | | |
| | | 403 | | public ImmutableArray<PropertyModel> Properties { get; } = properties; |
| | | 404 | | } |
| | | 405 | | |
| | | 406 | | private sealed class PropertyModel(string name, bool ignoreModificationTracking, bool reactsToCulture, bool reactsTo |
| | | 407 | | { |
| | | 408 | | public string Name { get; } = name; |
| | | 409 | | |
| | | 410 | | public bool IgnoreModificationTracking { get; } = ignoreModificationTracking; |
| | | 411 | | |
| | | 412 | | public bool ReactsToCulture { get; } = reactsToCulture; |
| | | 413 | | |
| | | 414 | | public bool ReactsToTimeZone { get; } = reactsToTimeZone; |
| | | 415 | | |
| | | 416 | | public bool PropertyChangedForwarding { get; } = propertyChangedForwarding; |
| | | 417 | | |
| | | 418 | | public bool ConcatenateForwardedPropertyName { get; } = concatenateForwardedPropertyName; |
| | | 419 | | |
| | | 420 | | public ImmutableArray<string> ValidationDependents { get; } = validationDependents; |
| | | 421 | | } |
| | | 422 | | } |
| | | 423 | | |