CodeSmith Community
Your Code. Your Way. Faster!

Validation Application Block

Latest post 12-03-2007 3:58 PM by katokay. 7 replies.
  • 02-01-2007 8:35 AM

    • katokay
    • Top 25 Contributor
    • Joined on 07-09-2006
    • Salt Lake City, UT
    • Posts 143
    • Points 3,190

    Validation Application Block

    I hope when the Enterprise Library 3.0 is officially released that .netTiers will incorporate the Validation Application Block.
    • Post Points: 90
  • 02-01-2007 11:17 AM In reply to

    • Don
    • Top 100 Contributor
    • Joined on 11-03-2006
    • Posts 48
    • Points 1,000

    Re: Validation Application Block

    I second that!
    • Post Points: 5
  • 03-26-2007 8:35 AM In reply to

    • drel
    • Top 200 Contributor
    • Joined on 12-07-2006
    • Posts 25
    • Points 540

    Re: Validation Application Block

    I third that!
    • Post Points: 5
  • 04-10-2007 12:14 PM In reply to

    • Don
    • Top 100 Contributor
    • Joined on 11-03-2006
    • Posts 48
    • Points 1,000

    Re: Validation Application Block

    It has been officially released!
    • Post Points: 35
  • 04-11-2007 11:25 AM In reply to

    Re: Validation Application Block

    Yes, it's on our list of things to be implemented.  The one caveat is how we're going to handle the Validation Engine.  Since EntLib's is Attribute based, we'll have to find a way of  letting you guys still use your own rules.

    Robert Hinojosa
    -------------------------------------
    Member of the Codesmith Tools, .netTiers, teams
    http://www.nettiers.com
    -------------------------------------
    • Post Points: 35
  • 04-11-2007 4:23 PM In reply to

    • katokay
    • Top 25 Contributor
    • Joined on 07-09-2006
    • Salt Lake City, UT
    • Posts 143
    • Points 3,190

    Re: Validation Application Block

    It can be attribute based, but can also be programatic, or config based also.
    Filed under:
    • Post Points: 5
  • 05-24-2007 8:11 AM In reply to

    • katokay
    • Top 25 Contributor
    • Joined on 07-09-2006
    • Salt Lake City, UT
    • Posts 143
    • Points 3,190

    Re: Validation Application Block

    I posted a patch here that uses the Validation Block. It uses the same constraints that were originally enforced by .netTiers using attributes. You can "own" or override the validation in the subclasses by specifying different or additive rules. The Validation Block will use the subclass rules over the base class. If there are more complex validation scenarios the subclass can also add any method with a [SelfValidation] attribute and a parameter of ValidationResults to perform additional validation. It would also be trivial to implement (provided my feature request is granted) a config file based validation file, which in my opinion is the most flexible solution for applications using the Validation Block.

     Edit: Also one issue left unresolved. The validation block can specify different rulesets. Currently it uses "NetTiers" as the ruleset name. It would be nice to expose a property somewhere to change the ruleset at runtime. Where would be a good place to do this. I can see it being useful to set global and entity specific rulesets.

    • Post Points: 5
  • 12-03-2007 3:58 PM In reply to

    • katokay
    • Top 25 Contributor
    • Joined on 07-09-2006
    • Salt Lake City, UT
    • Posts 143
    • Points 3,190

    Re: Validation Application Block

    I have updated the patch for svn 677. I have made EntLib validation an option with .netTiers as the default.

    Filed under:
    • Post Points: 5
Page 1 of 1 (8 items) | RSS
Copyright © 2008 CodeSmith Tools, LLC
Powered by Community Server (Commercial Edition), by Telligent Systems