Пример #1
0
        private void ManufacturerInitializeComputersFromInput()
        {
            var manufacturerName = Console.ReadLine();

            ManufacturerFactory manufacturerCreator = new ManufacturerFactory();

            ComputersFactory manufacturer = manufacturerCreator.CreateManufacturer(manufacturerName);

            this.pc     = manufacturer.CreatePc();
            this.laptop = manufacturer.CreateLaptop();
            this.server = manufacturer.CreateServer();
        }
 public FactoryBuilder(ComputersFactory factory)
 {
     this.factory = factory;
 }