示例#1
0
        private static ValidationErrors ValidateObject(Test123 obj)
        {
            ValidationErrorsBuilder e = default(ValidationErrorsBuilder);

            e.Add(BasicValidators.NotEmpty(obj.Field543).Nest("Field543"));
            e.Add(BasicValidators.Range(1, 10, obj.AbcSS).Nest("abcSS"));
            return(e.Build());
        }
示例#2
0
 private static ValidationErrors ValidateObject(T obj)
 {
     return(BasicValidators.NotEmpty(obj.B).Nest("b"));
 }