我正在查看http://www.asp.net/web-api/overview/getting-started-with-aspnet-web-api/tutorial-your-first-web-api上的代码示例
作为一个练习,我试图将它从C#翻译成vb.net但是没有运气这个片段,
public class Product
{
public int Id { get; set; }
public string Name { get; set; }
public string Category { get; set; }
public decimal Price { get; set; }
}
Product[] products = new Product[]
{ new Product { Id = 1, Name = "Tomato Soup", Category = "Groceries", Price = 1 },
new Product { Id = 2, Name = "Yo-yo", Category = "Toys", Price = 3.75M },
new Product { Id …Run Code Online (Sandbox Code Playgroud)