Beispiel #1
0
        public void VehicleLoading()
        {
            string licenseNumber = GarageUI.GetLicenseNumber();

            if (licenseNumber != null)
            {
                float addCharging = GarageUI.GetAmountElectric();

                try
                {
                    garage.VehicleLoading(licenseNumber, addCharging);
                    GarageUI.MesegeSucceeded();
                }
                catch (ValueOutOfRangeException)
                {
                    GarageUI.MesegeError();
                }
            }
            else
            {
                GarageUI.NotHaveVehicleInGarage();
            }
            GarageUI.MesegeToContinue();
        }