Welcome to mirror list, hosted at ThFree Co, Russian Federation.

Global.tt « Templates « AspNet « addins « src « main - github.com/mono/monodevelop.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 11cbbbe7702d513008733b8ba2bbb2b087afd7d3 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
<#@ template language="C#" #>
<#
bool webApi = IsTrue ("UsesAspNetWebApi");
bool mvc = IsTrue ("UsesAspNetMvc");
#>
using System.Web;
<# if (mvc) { #>
using System.Web.Mvc;
using System.Web.Routing;
<# } #>
<# if (webApi) { #>
using System.Web.Http;
<# } #>

namespace <#=Tags["Namespace"]#>
{
	public class Global : HttpApplication
	{
		protected void Application_Start()
		{
<# if (mvc) { #>
			AreaRegistration.RegisterAllAreas();
<# } #>
<# if (webApi) { #>
			GlobalConfiguration.Configure(WebApiConfig.Register);
<# } #>
<# if (mvc) { #>
			RouteConfig.RegisterRoutes(RouteTable.Routes);
<# } #>
		}
	}
}