Ejemplo n.º 1
0
        private string RandomModel(VehicleMakeInfo make)
        {
            int max   = make.Models.Count;
            int index = utils.RandomInteger(0, max - 1);

            try
            {
                return(make.Models[index]);
            }
            catch
            {
                return(make.Models.First());
            }
        }
        public static List <VehicleMakeInfo> AllMakes()
        {
            List <VehicleMakeInfo> result = new List <VehicleMakeInfo>();

            result.Add(VehicleMakeInfo.Acura());
            result.Add(VehicleMakeInfo.Audi());
            result.Add(VehicleMakeInfo.BMW());
            result.Add(VehicleMakeInfo.Cadillac());
            result.Add(VehicleMakeInfo.Chevy());
            result.Add(VehicleMakeInfo.Chrysler());
            result.Add(VehicleMakeInfo.Dodge());
            result.Add(VehicleMakeInfo.Fiat());
            result.Add(VehicleMakeInfo.Ford());
            result.Add(VehicleMakeInfo.GMC());
            result.Add(VehicleMakeInfo.Honda());
            result.Add(VehicleMakeInfo.Lexus());
            result.Add(VehicleMakeInfo.Mini());
            result.Add(VehicleMakeInfo.Porsche());
            result.Add(VehicleMakeInfo.Smart());
            result.Add(VehicleMakeInfo.Toyota());
            result.Add(VehicleMakeInfo.Volvo());
            return(result);
        }