public void addPymentMethodWithEntityFramework()
        {
            var customer = new Customer { name = "Sciemniacz" };
            var creditCardPaymentMethod = new CreditCardPaymentMethod() { cardHolderName = "Roman", cardNumber = "123123", cardType = "visa", registrationDate = DateTime.Now, status = 1, AssignedTo = customer};
            var directDebitPaymentMethod = new DirectDebitPaymentMethod()
                                    {bankAccountNumber = "12345", holderName = "Roman", registrationDate = DateTime.Now, status = 2, AssignedTo = customer};
            customer.UsedPaymentMethod = creditCardPaymentMethod;
            var entities = new Entities();

            entities.AddToPaymentMethodSet(creditCardPaymentMethod);
            entities.AddToPaymentMethodSet(directDebitPaymentMethod);
            entities.SaveChanges();

            var entities1 = new Entities();
            List<PaymentMethod> paymentMethods = entities1.PaymentMethodSet
                .Where(x => x.registrationDate < DateTime.Now)
                .ToList();
            foreach (var paymentMethod in paymentMethods)
            {
                   Console.WriteLine(paymentMethod.GetType());
            }
        }
 /// <summary>
 /// Create a new CreditCardPaymentMethod object.
 /// </summary>
 /// <param name="id">Initial value of the id property.</param>
 /// <param name="status">Initial value of the status property.</param>
 /// <param name="registrationDate">Initial value of the registrationDate property.</param>
 public static CreditCardPaymentMethod CreateCreditCardPaymentMethod(global::System.Int32 id, global::System.Byte status, global::System.DateTime registrationDate)
 {
     CreditCardPaymentMethod creditCardPaymentMethod = new CreditCardPaymentMethod();
     creditCardPaymentMethod.id = id;
     creditCardPaymentMethod.status = status;
     creditCardPaymentMethod.registrationDate = registrationDate;
     return creditCardPaymentMethod;
 }