Beispiel #1
0
 public bool CanPurchase(Person p)
 {
     if (!(PersonValidatorStatic.IsValid(p)))
     {
         throw new Exception("validation failed");
     }
     if (p.SSID!=null &&
         p.SubscriptionType!=null &&
         p.CreditOnFile>0)
     {
         return true;
     }
     return false;
 }
        public bool CanPurchase(Person p)
        {
            if (!(validator.IsValid(p)))
            {
                return false;
            }

            if (p.SSID!=null &&
                p.SubscriptionType!=null &&
                p.CreditOnFile>0)
            {
                return true;
            }

            return false;
        }
Beispiel #3
0
 public static bool CheckValue(Person p)
 {
     return false;
 }
Beispiel #4
0
 public static void LogPersonCreate(Person person)
 {
     string error = "Log file not configured!";
     Thread.Sleep(2 * 1000);
     throw new Exception(error);
 }