Beispiel #1
0
 public IsUrl(Expression <Func <TViewModel, string> > propToValidateExpression)
 {
     ConstructorArguments = new List <object> {
         propToValidateExpression
     };
     _propToValidateExpression = propToValidateExpression;
     PropertyFilter            = new UglyExpressionConvertor().ToString(_propToValidateExpression);
 }
Beispiel #2
0
 public IsValidCaptcha(Expression <Func <TViewModel, string> > questionPropertyExpression, Expression <Func <TViewModel, string> > answerPropertyExpression)
 {
     ConstructorArguments = new List <object> {
         questionPropertyExpression, answerPropertyExpression
     };
     _questionPropertyExpression = questionPropertyExpression;
     _answerPropertyExpression   = answerPropertyExpression;
     PropertyFilter    = new UglyExpressionConvertor().ToString(_questionPropertyExpression);
     _captchaEvaluator = new CaptchaEvaluator();
 }
Beispiel #3
0
 public Property(Expression<Func<PropertyInfo, bool>> filter)
 {
     Match = filter;
     _expressionString = new UglyExpressionConvertor().ToString(Match);
 }