/// <summary> /// /// </summary> protected void Application_Start() { LoggerGlobal.GlobalInit(); AutoMapperConfig.Initialize(); RegisterAndResolverIoc(); GlobalConfiguration.Configure(WebApiConfig.Register); }
protected void Application_Start() { FilterConfig.RegisterGlobalFilters(GlobalFilters.Filters); AreaRegistration.RegisterAllAreas(); RouteConfig.RegisterRoutes(RouteTable.Routes); LoggerGlobal.GlobalInit(); AutoMapperConfig.Initialize(); RegisterAndResolverIoc(); }
protected void Application_Start() { AreaRegistration.RegisterAllAreas(); FilterConfig.RegisterGlobalFilters(GlobalFilters.Filters); RouteConfig.RegisterRoutes(RouteTable.Routes); BundleConfig.RegisterBundles(BundleTable.Bundles); //启动日志服务 LoggerGlobal.GlobalInit(); }
protected void Application_Start() { //初始化日志组件 LoggerGlobal.GlobalInit(); GlobalConfiguration.Configure(WebApiConfig.Register); AutoMapperConfig.Initialize(); GlobalConfiguration.Configuration.MessageHandlers.Add(new AuthorizationHandler()); RegisterAndResolverIoc(); }
/// <summary> /// 应用程序的主入口点。 /// </summary> static void Main() { LoggerGlobal.GlobalInit(); RegisterAndResolverIoc();//注册服务 AutoMapperConfig.Initialize(); //ServiceBase[] ServicesToRun; //ServicesToRun = new ServiceBase[] //{ // new Service1() //}; //ServiceBase.Run(ServicesToRun); Application.Run(new Form1()); }