public StorageMaster() { this.producPool = new List <Product>(); this.storageRegister = new List <Storage>(); this.productFactory = new ProductFactory(); this.storageFactory = new StorageFactory(); }
public StorageMaster() { this.productPool = new Dictionary <string, Stack <Product> >(); this.storageRegistry = new Dictionary <string, Storage>(); this.productFactory = new ProductFactory(); this.storageFactory = new StorageFactory(); }
public string AddProduct(string type, double price) { ProductFactory productFactory = new ProductFactory(); Product product = productFactory.CreateProduct(type, price); this.productsPool.Add(product); return($"Added {type} to pool"); }
public StorageMaster() { products = new Dictionary <string, Stack <Product> >(); storages = new Dictionary <string, Storage>(); productFactory = new ProductFactory(); storageFactory = new StorageFactory(); }
//Constructors public StorageMaster() { this.pool = new List <Product>(); this.storages = new List <Storage>(); this.productFactory = new ProductFactory(); this.vehicleFactory = new VehicleFactory(); this.storageFactory = new StorageFactory(); }
public StorageMaster() { this.storages = new List <Storage>(); this.products = new List <Product>(); this.vehicles = new List <Vehicle>(); this.productFactory = new ProductFactory(); this.storageFactory = new StorageFactory(); this.currentVehicle = null; }
public static void Main() { var productFactory = new ProductFactory(); var storageFactory = new StorageFactory(); var storageMaster = new StorageMaster(productFactory, storageFactory); var consoleDataReader = new ConsoleDataReader(); var consoleDataWriter = new ConsoleDataWriter(); var engine = new Engine(storageMaster, consoleDataReader, consoleDataWriter); engine.Run(); }
static void Main(string[] args) { var storageFac = new StorageFactory(); var storageRepo = new StorageRepository(); var productFac = new ProductFactory(); var productRepo = new ProductRepository(); var master = new Core.StorageMaster(productFac, productRepo, storageFac, storageRepo); var reader = new Reader(); var writer = new Writer(); var engine = new Engine(master, reader, writer); engine.Run(); }