static void Main(string[] args) { VendingMachine thisVM = new VendingMachine(); UserInterface custInterface = new UserInterface(thisVM); custInterface.Run(); }
static void Main(string[] args) { VendingMachine VM = new VendingMachine(); UserInterface UI = new UserInterface(VM); UI.Run(); }
static void Main(string[] args) { VendingMachine test = new VendingMachine(); UserInterface thisUserInterface = new UserInterface(test); thisUserInterface.Run(); }
static void Main(string[] args) { // Get the connection string from the appsettings.json file IConfigurationBuilder builder = new ConfigurationBuilder() .SetBasePath(Directory.GetCurrentDirectory()) .AddJsonFile("appsettings.json", optional: true, reloadOnChange: true); IConfigurationRoot configuration = builder.Build(); string connectionString = configuration.GetConnectionString("Project"); UserInterface ui = new UserInterface(connectionString); ui.Run(); }
static void Main(string[] args) { #region call to appsettings.json for configuration // Get the connection string from the appsettings.json file IConfigurationBuilder builder = new ConfigurationBuilder() .SetBasePath(Directory.GetCurrentDirectory()) .AddJsonFile("appsettings.json", optional: true, reloadOnChange: true); IConfigurationRoot configuration = builder.Build(); #endregion string connectionString = configuration.GetConnectionString("Project"); // Create a new object of type VenueDAO so that we can pass it into the User Interface. IVenueDAO venueDAO = new VenueDAO(connectionString); // Create a new object of type SpaceDAO so that we can pass it into the User Interface. ISpaceDAO spaceDAO = new SpaceDAO(connectionString); // Create a new object of type ReservationDAO so that we can pass it into the User Interface. IReserveDAO reserveDAO = new ReservationDAO(connectionString); UserInterface ui = new UserInterface(connectionString, venueDAO, spaceDAO, reserveDAO); ui.Run(); }