如何为我的entier项目创建一个验证层? [英] How can a saparately create a validation layer for my entier project?

查看:88
本文介绍了如何为我的entier项目创建一个验证层?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在我的项目中,我正在使用 N层架构。在这里,我想为字段和数据验证创建一个单独的图层。这样我就可以通过应用程序轻松管理我的验证代码。请帮我创建验证层

In my project I am using N-tier architecture. Here I want to make a separate layer for field and data validation. So that I can easily manage my validation code through out the application. Please help me to create validation layer.

推荐答案

看看这个CodeProject文章 http://www.codeproject.com/Articles/430014/N-Tier-Architecture-and-提示#N-Tier架构中的业务数据验证 [ ^ ]

具体提到验证



Beyond你需要做更多的研究,和/或发布你正在努力解决的代码
Have a look at this CodeProject article http://www.codeproject.com/Articles/430014/N-Tier-Architecture-and-Tips#Business Data Validation in N-Tier Architecture[^]
It specifically mentions validation

Beyond that you need to do a little more research, and/or post the code that you are struggling with


我从这里得到了解决方案



常规验证和长度验证EXP ASP.NET中的ressions [ ^ ]
I have got the solutions from here

Common Validation and Length Validation with Regular Expressions in ASP.NET[^]


http://msdn.microsoft.com/en-us/library/vstudio/dd409395.aspx [ ^ ]



AND

http://msdn.microsoft.com/en-us/library/dd409395 (v = vs.100).aspx [ ^ ]


这篇关于如何为我的entier项目创建一个验证层?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆