public void ChangeVehicleState(string i_LicenseNumber, eVehicleConditions i_State) { bool isVehicleExists = false; if (m_VehiclesInGarage.ContainsKey(i_LicenseNumber)) { m_VehiclesInGarage[i_LicenseNumber].VehicleState = i_State; isVehicleExists = true; } if (!isVehicleExists) { throw new Exception("Error, This license number does not exist in the garage!"); } }
public VehicleInGarage(Vehicle i_Vehicle, Owner i_Owner) { m_Vehicle = i_Vehicle; m_Owner = i_Owner; m_VehicleState = eVehicleConditions.InRepair; }