public VehiclesInGarage(Vehicle i_Vheicle, string i_OwnersName, string i_OwnersTelephone) { m_Vehicle = i_Vheicle; m_OwnersName = i_OwnersName; m_OwnersTelephone = i_OwnersTelephone; m_State = eStateInGarage.RepairInProgress; }
public GarageClient(string i_OwnerName, string i_OwnerPhoneNumber, Vehicle i_vehicle) { r_OwnerName = i_OwnerName; r_OwnerPhoneNumber = i_OwnerPhoneNumber; r_Vehicle = i_vehicle; m_StateInGarage = eStateInGarage.InAmendment; }
public List <string> GetLicenseNumbersOfVehicles(string i_StateInGarage) { bool getAllLicense; List <string> licenseNumbers = new List <string>(); eStateInGarage garageStateToCheck = (eStateInGarage)Enum.Parse(typeof(eStateInGarage), i_StateInGarage); getAllLicense = !Enum.IsDefined(typeof(eStateInGarage), garageStateToCheck); foreach (KeyValuePair <string, GarageClient> item in m_Vehicls) { if (item.Value.StateInGarage == garageStateToCheck || getAllLicense) { licenseNumbers.Add(item.Key); } } return(licenseNumbers); }
public void ChangeStateOfVehicle(string i_LicenseNumber, string i_NewState) { eStateInGarage garageState = ParseUtils.EnumParse <eStateInGarage>(i_NewState, " it is not a state in the Garage"); m_Vehicls[i_LicenseNumber].StateInGarage = garageState; }