Esempio n. 1
0
        public static void Main(string[] args)
        {
            OrderShipment service = new UpsOrderShipment();

            service.ShippingAddress = "New York";
            service.Ship(Console.Out);

            OrderShipment serviceTwo = new FedExOrderShipment();

            serviceTwo.ShippingAddress = "Los Angeles";
            serviceTwo.Ship(Console.Out);

            Console.ReadKey();
        }
Esempio n. 2
0
        public static void Main(string[] args)
        {
            Console.WriteLine("UPS");
            OrderShipment orderShipment = new UpsOrderShipment("Wroclaw");

            orderShipment.Ship();

            Console.WriteLine();

            Console.WriteLine("FEDEX");
            orderShipment = new FedexOrderShipment("Wroclaw");
            orderShipment.Ship();

            Console.ReadKey();
        }