mirror of
https://github.com/BepInEx/mono.git
synced 2026-11-17 01:41:17 -10:00
* System.Web.dll.sources: added WebConfigurationSettings. * System.Web/HttpContext.cs: updated GetConfig and GetAppConfig to new API. * System.Web/HttpResponse.cs: separate initialization of the HttpWriter, as it tries to read configuration settings while the config. system is not available (ie, before the first request). * System.Web/HttpRuntime.cs: delayed queueManager and response writer initialization until the configuration system is working. * System.Web.Configuration/GlobalizationConfiguration.cs: return null when the configuration is not available. * System.Web.Util/WebEncoding.cs: use the Default encoding when the globalization configuration is not available. * System.Web.Configuration/WebConfigurationSettings.cs: handle configuration for System.Web. It replaces the default IConfigurationSystem with itself and handles web.config files oddities. * System.Web.UI.WebControls/WebControl.cs: don't create the attributes when GetAttribute is called. svn path=/trunk/mcs/; revision=20681
50 lines
993 B
C#
50 lines
993 B
C#
//
|
|
// System.Web.Util.WebEncoding
|
|
//
|
|
// Authors:
|
|
// Gonzalo Paniagua Javier ([email protected])
|
|
//
|
|
// (C) 2002 Ximian, Inc (http://www.ximian.com)
|
|
// (C) 2003 Novell, Inc (http://www.novell.com)
|
|
//
|
|
|
|
using System.Text;
|
|
using System.Web.Configuration;
|
|
|
|
namespace System.Web.Util
|
|
{
|
|
internal class WebEncoding
|
|
{
|
|
static public Encoding FileEncoding {
|
|
get {
|
|
GlobalizationConfiguration gc = GlobalizationConfiguration.GetInstance (null);
|
|
if (gc == null)
|
|
return Encoding.Default;
|
|
|
|
return gc.FileEncoding;
|
|
}
|
|
}
|
|
|
|
static public Encoding ResponseEncoding {
|
|
get {
|
|
GlobalizationConfiguration gc = GlobalizationConfiguration.GetInstance (null);
|
|
if (gc == null)
|
|
return Encoding.Default;
|
|
|
|
return gc.ResponseEncoding;
|
|
}
|
|
}
|
|
|
|
static public Encoding RequestEncoding {
|
|
get {
|
|
GlobalizationConfiguration gc = GlobalizationConfiguration.GetInstance (null);
|
|
if (gc == null)
|
|
return Encoding.Default;
|
|
|
|
return gc.RequestEncoding;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|