/// <summary>
 /// Retrieves a collection of localized validation errors for the model and returns it.
 /// </summary>
 /// <param name="container">The container for the model.</param>
 /// <returns>A collection of localized validation errors for the model, or an empty collection if no errors have occurred.</returns>
 public override IEnumerable <ModelValidationResult> Validate(object container)
 {
     return(LocalizationHelper.LocalizeValidationResults(base.Validate(container), Metadata.GetDisplayName()));
 }
 /// <summary>
 /// Retrieves a collection of localized validation errors for the model and returns it.
 /// </summary>
 /// <param name="container">The container for the model.</param>
 /// <returns>A collection of localized validation errors for the model, or an empty collection if no errors have occurred.</returns>
 public override IEnumerable <ModelValidationResult> Validate(object container)
 {
     return(LocalizationHelper.LocalizeValidationResults(base.Validate(container), Metadata.GetDisplayName(), Attribute.MinimumLength, Attribute.MaximumLength));
 }
 /// <summary>
 /// Retrieves a collection of localized client validation rules for the model and returns it.
 /// </summary>
 /// <returns>A collection of localized client validation rules for the model.</returns>
 public override IEnumerable <ModelClientValidationRule> GetClientValidationRules()
 {
     return(LocalizationHelper.LocalizeValidationRules(base.GetClientValidationRules(), Metadata.GetDisplayName(), Attribute.MinimumLength, Attribute.MaximumLength));
 }
 /// <summary>
 /// Retrieves a collection of localized client validation rules for the model and returns it.
 /// </summary>
 /// <returns>A collection of localized client validation rules for the model.</returns>
 public override IEnumerable <ModelClientValidationRule> GetClientValidationRules()
 {
     return(LocalizationHelper.LocalizeValidationRules(base.GetClientValidationRules(), Metadata.GetDisplayName()));
 }