Exemplo n.º 1
0
        public void execute()
        {
            OptionFactory    factory          = new OptionFactory();
            RequestedVehicle requestedVehicle = new RequestedVehicle();

            requestedVehicle.addOption("air bag", 80, factory);
            requestedVehicle.addOption("electry glasses", 80, factory);

            requestedVehicle.showOptions();
        }
Exemplo n.º 2
0
 public void addOption(string name, int salePrice, OptionFactory factory)
 {
     this.options.Add(factory.getOption(name));
     this.optionsSalePrices.Add(salePrice);
 }