mirror of
https://github.com/BepInEx/mono.git
synced 2026-11-16 17:10:20 -10:00
* ApplicationFileParser.cs: it works now. Prior to these changes, we were using the compiler directly. * BaseParser.cs: added some useful properties and methods. * CodeBuilder.cs: use ILocation. * CodeRenderBuilder.cs: use ILocation. * CollectionBuilder.cs: use the RootBuilder to map tag names into Types. * ControlBuilder.cs: made it useful. * DataBindingBuilder.cs: the control type for data bound text is DataBoundLiteralControl now. * ObjectTagBuilder.cs: store some object tag attributes. * PageParser.cs: handle page-only directives. * RootBuilder.cs: bah. * SimpleWebHandlerParser.cs: made it dummy. * TemplateControl.cs: Modified file. * TemplateControlParser.cs: handle directives that are common to pages and user controls. * TemplateParser.cs: utility methods and handling of directives that are common to app, page and user controls. * UserControl.cs: added ControlBuilderAttribute. * UserControlControlBuilder.cs: builder for user controls. * UserControlParser.cs: use the new interfaces. svn path=/trunk/mcs/; revision=14142
53 lines
1.1 KiB
C#
53 lines
1.1 KiB
C#
//
|
|
// System.Web.UI.UserControlParser
|
|
//
|
|
// Authors:
|
|
// Gonzalo Paniagua Javier ([email protected])
|
|
//
|
|
// (C) 2002,2003 Ximian, Inc (http://www.ximian.com)
|
|
//
|
|
using System;
|
|
using System.IO;
|
|
using System.Web;
|
|
using System.Web.Compilation;
|
|
|
|
namespace System.Web.UI
|
|
{
|
|
public sealed class UserControlParser : TemplateControlParser
|
|
{
|
|
internal UserControlParser (string virtualPath, string inputFile, HttpContext context)
|
|
{
|
|
Context = context;
|
|
CurrentVirtualPath = virtualPath;
|
|
InputFile = Path.Combine (context.Request.MapPath (virtualPath), inputFile);
|
|
}
|
|
|
|
public static Type GetCompiledType (string virtualPath, string inputFile, HttpContext context)
|
|
{
|
|
UserControlParser ucp = new UserControlParser (virtualPath, inputFile, context);
|
|
return ucp.CompileIntoType ();
|
|
}
|
|
|
|
protected override Type CompileIntoType ()
|
|
{
|
|
AspGenerator generator = new AspGenerator (this);
|
|
return generator.GetCompiledType ();
|
|
}
|
|
|
|
protected override Type DefaultBaseType
|
|
{
|
|
get {
|
|
return typeof (UserControl);
|
|
}
|
|
}
|
|
|
|
protected internal override string DefaultDirectiveName
|
|
{
|
|
get {
|
|
return "control";
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|