Example #1
0
        public void InsertNewCustomer(string i_NumberOfCarLicense, Utilities.eTypeOfVehicle i_VehicleType, string i_ModelName, string i_NameOfManufacturer, float i_CurTirePressure, string i_NameOfVehicleOwner, string i_PhoneNumber)
        {
            Vehicle  createdVehicle  = VehicleCreator.CreateVehicle(i_VehicleType, i_ModelName, i_NumberOfCarLicense, i_NameOfManufacturer, i_CurTirePressure);
            Customer createdCustomer = new Customer(createdVehicle, i_NameOfVehicleOwner, i_PhoneNumber);

            m_CustomerList.Add(createdCustomer);
        }
Example #2
0
 public void AddNewVehicleToGarage(string i_LicenseNumber, VehicleCreator.eVehicleType i_VehicleType)
 {
     if (r_Vehicles.ContainsKey(i_LicenseNumber))
     {
         r_Vehicles[i_LicenseNumber].VehicleStatus = Vehicle.eVehicleStatus.InRepair;
     }
     else
     {
         Vehicle newVehicle = VehicleCreator.CreateVehicle(i_LicenseNumber, i_VehicleType);
         r_Vehicles.Add(i_LicenseNumber, newVehicle);
         if (newVehicle.Engine is FuelEngine)
         {
             m_NumberOfFuelVehicles++;
         }
         else
         {
             m_NumberOfElectricVehicles++;
         }
     }
 }
Example #3
0
        public void CreateNewVehicle(string i_VehicleTypeNumber, string i_LicenseNumber, string i_OwnerName, string i_PhoneNumber)
        {
            Vehicle vehicle = VehicleCreator.CreateVehicle(i_VehicleTypeNumber, i_LicenseNumber);

            addVehicleToGarage(i_LicenseNumber, vehicle, i_OwnerName, i_PhoneNumber);
        }