Ejemplo n.º 1
0
        static void Main(string[] args)
        {
            IPaymentState paypalPaymentState = new PayPalPaymentState();
            IPaymentState cardPaymentState = new CardPaymentState();
            IPaymentState rambursPaymenState = new RambursPaymentState();

            Order order = new Order();
            order.Amount = 100.0;

            paypalPaymentState.Pay(order);
        }
Ejemplo n.º 2
0
        static void Main(string[] args)
        {
            IPaymentState paypalPaymentState = new PayPalPaymentState();
            IPaymentState cardPaymentState   = new CardPaymentState();
            IPaymentState rambursPaymenState = new RambursPaymentState();

            Order order = new Order();

            order.Amount = 100.0;

            paypalPaymentState.Pay(order);
        }