<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:georss="http://www.georss.org/georss" xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:media="http://search.yahoo.com/mrss/"
		>
<channel>
	<title>Comments on: Rhino-Tools a smarter Guard</title>
	<atom:link href="http://chornsokun.wordpress.com/2009/04/10/rhino-tools-a-smarter-guard/feed/" rel="self" type="application/rss+xml" />
	<link>http://chornsokun.wordpress.com/2009/04/10/rhino-tools-a-smarter-guard/</link>
	<description>try { divide and conquer; } catch { keep it simple!; } finally { nothing is impossible; }</description>
	<lastBuildDate>Wed, 30 Dec 2009 04:47:37 +0000</lastBuildDate>
	<generator>http://wordpress.com/</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: Chorn Sokun</title>
		<link>http://chornsokun.wordpress.com/2009/04/10/rhino-tools-a-smarter-guard/#comment-260</link>
		<dc:creator>Chorn Sokun</dc:creator>
		<pubDate>Fri, 10 Apr 2009 09:09:41 +0000</pubDate>
		<guid isPermaLink="false">http://chornsokun.wordpress.com/?p=463#comment-260</guid>
		<description>jQuery validation I believe in Defend in deep user may by pass client-side validation.
I can still report problems to the client via ajaxForm()</description>
		<content:encoded><![CDATA[<p>jQuery validation I believe in Defend in deep user may by pass client-side validation.<br />
I can still report problems to the client via ajaxForm()</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Samnang</title>
		<link>http://chornsokun.wordpress.com/2009/04/10/rhino-tools-a-smarter-guard/#comment-258</link>
		<dc:creator>Samnang</dc:creator>
		<pubDate>Fri, 10 Apr 2009 08:31:12 +0000</pubDate>
		<guid isPermaLink="false">http://chornsokun.wordpress.com/?p=463#comment-258</guid>
		<description>If so, how do you handle form validation on client side?</description>
		<content:encoded><![CDATA[<p>If so, how do you handle form validation on client side?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Chorn Sokun</title>
		<link>http://chornsokun.wordpress.com/2009/04/10/rhino-tools-a-smarter-guard/#comment-256</link>
		<dc:creator>Chorn Sokun</dc:creator>
		<pubDate>Fri, 10 Apr 2009 06:19:06 +0000</pubDate>
		<guid isPermaLink="false">http://chornsokun.wordpress.com/?p=463#comment-256</guid>
		<description>I thought about NHV, Castle Validation etc.
But I prefer to handle the rule myself in general I would wrap validation logic like:

Service.dll
[sourcecode language=&#039;csharp&#039;]
TryDelete(entity)
 new Guard()
   .Check(...)
   .Check(...)
   .Check(...)
   .Report();

DeleteEntity(entity)
  TryDelete(entity);
  // ... deleted
[/sourcecode]

From controller point of view I can do:
When request for delete an entity
[sourcecode language=&#039;csharp&#039;]
public void RequestDelete(Entity entity){
   try{
      Service.TryDelete(entity);
   }catch(GuardSpotException ex){
      // extract detail error summary
   }
}

public void RealDelete(Entity entity, string token){
  try{
    Service.Delete(entity);
  }catch(GuardSpotException ex){
    // extract detail error summary
  }
} 
[/sourcecode]
it just all POCO no additional learning required.</description>
		<content:encoded><![CDATA[<p>I thought about NHV, Castle Validation etc.<br />
But I prefer to handle the rule myself in general I would wrap validation logic like:</p>
<p>Service.dll</p>
<pre class="brush: csharp;">
TryDelete(entity)
 new Guard()
   .Check(...)
   .Check(...)
   .Check(...)
   .Report();

DeleteEntity(entity)
  TryDelete(entity);
  // ... deleted
</pre>
<p>From controller point of view I can do:<br />
When request for delete an entity</p>
<pre class="brush: csharp;">
public void RequestDelete(Entity entity){
   try{
      Service.TryDelete(entity);
   }catch(GuardSpotException ex){
      // extract detail error summary
   }
}

public void RealDelete(Entity entity, string token){
  try{
    Service.Delete(entity);
  }catch(GuardSpotException ex){
    // extract detail error summary
  }
}
</pre>
<p>it just all POCO no additional learning required.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Samnang</title>
		<link>http://chornsokun.wordpress.com/2009/04/10/rhino-tools-a-smarter-guard/#comment-254</link>
		<dc:creator>Samnang</dc:creator>
		<pubDate>Fri, 10 Apr 2009 04:59:32 +0000</pubDate>
		<guid isPermaLink="false">http://chornsokun.wordpress.com/?p=463#comment-254</guid>
		<description>Nice way to validate input, but don&#039;t you think about using validation frameworks instead, because we don&#039;t want to repeat from controller to controller, we want to keep it in one place.

I have ever used similar thing(DBC) http://www.codeproject.com/KB/cs/designbycontract.aspx, but not for validating models.</description>
		<content:encoded><![CDATA[<p>Nice way to validate input, but don&#8217;t you think about using validation frameworks instead, because we don&#8217;t want to repeat from controller to controller, we want to keep it in one place.</p>
<p>I have ever used similar thing(DBC) <a href="http://www.codeproject.com/KB/cs/designbycontract.aspx" rel="nofollow">http://www.codeproject.com/KB/cs/designbycontract.aspx</a>, but not for validating models.</p>
]]></content:encoded>
	</item>
</channel>
</rss>
