mientras mira a Shrinkr 's código fuente (código fuente que toda opinión del otro proyecto para aprender, ¿no ??? :)) me di cuenta el siguiente código kewl .. (abreviado por mí, a continuación)Cualquier .NET Fluent Argument revisando bibliotecas por ahí?
public virtual Foo Foo
{
get;
set
{
Check.Argument.IsNotNull(value, "value");
// then do something.
}
}
Note la fluidez forma en que comprobar si hay argumentos? Agradable :)
alt text http://cherrythian.com/images/borat.jpg
Así que .. comprobar el código, de lo que cabe a medida que hace esto ...
public static class Check
{
public static class Argument
{
public static void IsNotNull(object parameter,
string parameterName)
{ ... }
public static void IsNotNullOrEmpty(string parameter,
string parameterName)
{ ... }
.... etc ....
}
¿Hay marcos comunes por ahí?
joya instalar netFluentCheck?
:)
CuttingEdge.Conditions es el shizzle ;-) – Steven