mirror of https://github.com/abpframework/abp.git
5 changed files with 73 additions and 52 deletions
@ -1,9 +1,12 @@ |
|||||
|
using System.Collections.Generic; |
||||
|
using System.ComponentModel.DataAnnotations; |
||||
|
|
||||
namespace Volo.Abp.Validation |
namespace Volo.Abp.Validation |
||||
{ |
{ |
||||
public interface IDataAnnotationValidator |
public interface IDataAnnotationValidator |
||||
{ |
{ |
||||
void Validate(object validatingObject); |
void Validate(object validatingObject); |
||||
|
|
||||
void AddErrors(IAbpValidationResult validationResult, object validatingObject); |
List<ValidationResult> GetErrors(object validatingObject); |
||||
} |
} |
||||
} |
} |
||||
@ -1,9 +1,16 @@ |
|||||
|
using System.Collections.Generic; |
||||
|
using System.ComponentModel.DataAnnotations; |
||||
|
|
||||
namespace Volo.Abp.Validation |
namespace Volo.Abp.Validation |
||||
{ |
{ |
||||
public interface IObjectValidator |
public interface IObjectValidator |
||||
{ |
{ |
||||
void Validate(object validatingObject, string name = null, bool allowNull = false); |
void Validate( |
||||
|
object validatingObject, |
||||
|
string name = null, |
||||
|
bool allowNull = false |
||||
|
); |
||||
|
|
||||
void AddErrors(IAbpValidationResult validationResult, object validatingObject, string name = null, bool allowNull = false); |
List<ValidationResult> GetErrors(object validatingObject, string name = null, bool allowNull = false); |
||||
} |
} |
||||
} |
} |
||||
Loading…
Reference in new issue