示例#1
0
 void Application_Start(object sender, EventArgs e)
 {
     // Code that runs on application startup
     AreaRegistration.RegisterAllAreas();
     GlobalConfiguration.Configure(WebApiConfig.Register);
     RouteConfig.RegisterRoutes(RouteTable.Routes);
     CustomLogging.Initialize(Server.MapPath("~"));
 }
示例#2
0
        public static HttpResponseMessage Test()
        {
            string _mess = "Web service is working";

            CustomLogging.LogMessage(TracingLevel.INFO, _mess);

            var resp = new HttpResponseMessage(HttpStatusCode.OK);

            resp.Content = new StringContent(_mess, System.Text.Encoding.UTF8, "text/plain");
            return(resp);
        }