2008-04-14 Igor Zelmanovich <igorz@mainsoft.com>
authorIgor Zelmanovich <igorz@mono-cvs.ximian.com>
Mon, 14 Apr 2008 16:21:46 +0000 (16:21 -0000)
committerIgor Zelmanovich <igorz@mono-cvs.ximian.com>
Mon, 14 Apr 2008 16:21:46 +0000 (16:21 -0000)
* HttpRuntime.cs: refactoring.

svn path=/trunk/mcs/; revision=100649

mcs/class/System.Web/System.Web/ChangeLog
mcs/class/System.Web/System.Web/HttpRuntime.cs

index bc2deedeb0263afc89e9365d231c86fb58278de1..c431dc951a5ea17f039a6d7ff923e820ad080bcc 100644 (file)
@@ -1,3 +1,7 @@
+2008-04-14  Igor Zelmanovich <igorz@mainsoft.com>
+
+       * HttpRuntime.cs: refactoring.
+
 2008-04-14  Marek Habersack  <mhabersack@novell.com>
 
        * XmlSiteMapProvider.cs: FindStartingNode throws an exception when
index 4f54d1f00d64aeacb6ce0923bc45fba8147da947..3783ae7dbf913b2395b06f8397e1b303965f6644 100644 (file)
@@ -59,6 +59,8 @@ namespace System.Web {
        // CAS - no InheritanceDemand here as the class is sealed
        [AspNetHostingPermission (SecurityAction.LinkDemand, Level = AspNetHostingPermissionLevel.Minimal)]
        public sealed class HttpRuntime {
+               static bool caseInsensitive;
+               static bool runningOnWindows;
 #if TARGET_J2EE
                static QueueManager queue_manager { get { return _runtime._queue_manager; } }
                static TraceManager trace_manager { get { return _runtime._trace_manager; } }
@@ -71,11 +73,6 @@ namespace System.Web {
                Cache _cache;
                Cache _internalCache;
 
-               static HttpRuntime ()
-               {
-                       do_RealProcessRequest = new WaitCallback (RealProcessRequest);
-               }
-
                public HttpRuntime ()
                {
                        WebConfigurationManager.Init ();
@@ -118,8 +115,6 @@ namespace System.Web {
                static WaitCallback do_RealProcessRequest;
                static Exception initialException;
                static bool firstRun;
-               static bool caseInsensitive;
-               static bool runningOnWindows;
                
 #if NET_2_0
                static bool assemblyMappingEnabled;
@@ -127,6 +122,15 @@ namespace System.Web {
                static object appOfflineLock = new object ();
 #endif
                
+#if ONLY_1_1
+               [SecurityPermission (SecurityAction.Demand, UnmanagedCode = true)]
+#endif
+               public HttpRuntime ()
+               {
+
+               }
+#endif
+
                static HttpRuntime ()
                {
                        PlatformID pid = Environment.OSVersion.Platform;
@@ -151,6 +155,7 @@ namespace System.Web {
                                }
                        }
                        
+#if !TARGET_J2EE
                        firstRun = true;
 #if NET_2_0
                        try {
@@ -177,17 +182,9 @@ namespace System.Web {
                        cache = new Cache ();
                        internalCache = new Cache ();
                        internalCache.DependencyCache = cache;
-                       do_RealProcessRequest = new WaitCallback (RealProcessRequest);
-               }
-
-#if ONLY_1_1
-               [SecurityPermission (SecurityAction.Demand, UnmanagedCode = true)]
 #endif
-               public HttpRuntime ()
-               {
-
+                       do_RealProcessRequest = new WaitCallback (RealProcessRequest);
                }
-#endif
                
 #region AppDomain handling
                //
@@ -643,7 +640,8 @@ namespace System.Web {
                        wr.CloseConnection ();
                }
 
-#if NET_2_0 && !TARGET_J2EE
+#if NET_2_0 
+#if !TARGET_J2EE
                static internal void WritePreservationFile (Assembly asm, string genericNameBase)
                {
                        if (asm == null)
@@ -708,7 +706,7 @@ namespace System.Web {
                                        AppDomain.CurrentDomain.AssemblyResolve -= new ResolveEventHandler (ResolveAssemblyHandler);
                        }
                }
-
+#endif // #if !TARGET_J2EE
                internal static bool RunningOnWindows {
                        get { return runningOnWindows; }
                }