static void Main(string[] args) { var builder = new RestfulApplicationBuilder(); builder.Build().StartAsync(); Console.Read(); }
static void Main(string[] args) { var builder = new RestfulApplicationBuilder(); var app = builder.ConfigServer(serverConfig => { serverConfig.Port = 10336; }).ConfigServiceProvider(serviceProvider => { serviceProvider.AddSigleton(typeof(Test), new Test("robot-001")); }).ConfigRestfulService(manager => { manager.Scan(Assembly.GetExecutingAssembly()); }).Build(); app.StartAsync(); Console.Read(); }