c# - NHibernate Validator Dynamic rules -
i'm using nhibernate , have requirement validation rules must change in time. framework i'll use nhibernate validator, don't know how make dynamic rules, validation quite simple xml files or attributes in entity class, catch make rules updatable. there way achieve this?
well, since nobody answered i'll explain how can achieved. can done special attributes within class [email] [notnull] [notempty] etc, , can changed/overridden xml files. in configuration file of nhibernate validator add tags each 1 of classes should controled this:
<mapping file="path.to.xml.validation.file">
and change default_validator_mode property overrideattributewithexternal
hope helps :)
Comments
Post a Comment