public override bool Validate(RuleValidation validator) { if (validator == null) { throw new ArgumentNullException("validator"); } if (this.codeDomStatement == null) { ValidationError error = new ValidationError(Messages.NullStatement, 0x53d); error.UserData["ErrorObject"] = this; validator.AddError(error); return(false); } return(CodeDomStatementWalker.Validate(validator, this.codeDomStatement)); }
public override bool Validate(RuleValidation validator) { if (validator == null) { throw new ArgumentNullException("validator"); } if (codeDomStatement == null) { ValidationError error = new ValidationError(Messages.NullStatement, ErrorNumbers.Error_ParameterNotSet); error.UserData[RuleUserDataKeys.ErrorObject] = this; validator.AddError(error); return(false); } else { return(CodeDomStatementWalker.Validate(validator, codeDomStatement)); } }