示例#1
0
        static void Main(string[] args)
        {
            VehicleRepo repo        = new VehicleRepo();
            var         allvehicles = repo.GetAllVehicles();

            foreach (var vehicle in allvehicles)
            {
                Console.WriteLine($"Name:{vehicle.Make}");
            }
            Console.ReadLine();
        }
示例#2
0
 public IHttpActionResult Get()
 {
     return(Ok(_repo.GetAllVehicles()));
 }