From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Dawson, Michael
Sent: Wednesday, November 03, 2004 3:29 PM
To: [EMAIL PROTECTED]
Subject: RE: [CFCDev] ValidationMurat, given your comment, how would you structure an application that validates its input? Would you have only a single object that both validates and handles the business logic (or even database transactions)?If so, would your single object then throw all possible types of errors for any condition such as invalid data or loss of database connection?ThanksM!ke
From: [EMAIL PROTECTED] on behalf of Murat Demirci
Sent: Wed 11/3/2004 6:54 AM
To: [EMAIL PROTECTED]
Subject: RE: [CFCDev] Validation
> One thing to keep in mind is that you need to make sure you're
> enforcing BUSINESS validation in your BO, not input validation, which
> should be enforced long before any data gets to your business layer.
>
> cheers,
> barneyb
The key point: what is the validation and its types? Does Business
Validation is really required after Input Validation?
IMHO, a strong input validation covers bussiness validation already, and
database provides extra validation for data-integrity. I think they are
enough, aren't they?
----------------------------------------------------------
You are subscribed to cfcdev. To unsubscribe, send an email
to [EMAIL PROTECTED] with the words 'unsubscribe cfcdev'
in the message of the email.
CFCDev is run by CFCZone (www.cfczone.org) and supported
by Mindtool, Corporation (www.mindtool.com).
An archive of the CFCDev list is available at www.mail-archive.com/[EMAIL PROTECTED]
Title: RE: [CFCDev] Validation
I
prefer the following structure for validations:
First
of all, validation is done when transferring data among application
layers.
Some
general application layers:
1) UI
(HTML)
i) Optional client-side validation is done before
sending data to the application
2)
Request Processor (event-handler(s) in Mach-II)
i) Server-side validation is done before putting data
to the BOs (by using event-filters); I think this validation is a
must.
3)
Application Objects and Services
i) Some extra optional validation before doing a task
(validation of cfqueryparam; or file existence validation)
4)
Database
i) Validation before storing data; I think this
validation is a must too.
Does
this make sense?
Shortly I mean validate() method in DTOs are wrong choice, IMHO.
Because it significantly decreases productivity and
flexibility.
Murat.
- RE: [CFCDev] Validation Murat Demirci
- RE: [CFCDev] Validation Murat Demirci
- Re: [CFCDev] Validation Barney Boisvert
- Re: [CFCDev] Validation Phil Cruz
- Re: [CFCDev] Validation Barney Boisvert
- Re: [CFCDev] Validation Phil Cruz
- Re: [CFCDev] Validation Barney Boisvert
- Re: [CFCDev] Validation Barney Boisvert
- RE: [CFCDev] Validation Murat Demirci
- Re: [CFCDev] Validation Barney Boisvert
- RE: [CFCDev] Validation Murat Demirci
