public virtual void AddValidator(ValidatorProperties validator) { var editComponent = EditColtrol as IRenderComponent; if (editComponent != null) { editComponent.AddValidator(validator); } else { ValidatorProperties.Add(validator); AddClientValidator(validator, ValidatorProperties.Count); } }
public virtual void AddValidators(IEnumerable <ValidatorProperties> validators) { var editComponent = EditColtrol as IRenderComponent; if (editComponent != null) { editComponent.AddValidators(validators); } else { foreach (var validator in validators) { ValidatorProperties.Add(validator); AddClientValidator(validator, ValidatorProperties.Count); } } }