public override void Initialize(RuleRunnerContext context)
 {
     // StrictMode scenario should be handled by MembersMustExist rule.
     if (!Settings.StrictMode)
     {
         context.RegisterOnMemberSymbolAction(RunOnMemberSymbol);
     }
 }
 /// <summary>
 /// Method that is called when the rules are created by the <see cref="IRuleRunner"/> in
 /// order to do the initial setup for the rule.
 /// </summary>
 /// <param name="context">The context that the <see cref="IRuleRunner"/> creates holding callbacks to get the differences.</param>
 public override void Initialize(RuleRunnerContext context)
 {
     // This rule should only run when not in strict mode.
     // When running in strict mode this diff will be handled by MembersMustExist rule.
     if (!Settings.StrictMode)
     {
         context.RegisterOnMemberSymbolAction(RunOnMemberMapperAction);
     }
 }
Beispiel #3
0
 /// <summary>
 /// Method that is called when the rules are created by the <see cref="IRuleRunner"/> in
 /// order to do the initial setup for the rule.
 /// </summary>
 /// <param name="context">The context that the <see cref="IRuleRunner"/> creates holding callbacks to get the differences.</param>
 public override void Initialize(RuleRunnerContext context)
 {
     context.RegisterOnTypeSymbolAction(RunOnTypeSymbol);
     context.RegisterOnMemberSymbolAction(RunOnMemberSymbol);
 }