Author: igorz
Date: 2008-02-12 09:30:39 -0500 (Tue, 12 Feb 2008)
New Revision: 95502
Added:
branches/mainsoft/gh2.2/mcs/class/System.Web/System.Web/IHttpExtendedWorkerRequest.cs
Modified:
branches/mainsoft/gh2.2/mcs/class/System.Web/System.Web.Phantom/System.Web.Phantom.csproj
branches/mainsoft/gh2.2/mcs/class/System.Web/System.Web/HttpRequest.jvm.cs
branches/mainsoft/gh2.2/mcs/class/System.Web/System.Web20.csproj
Log:
add new internal interface for extending HttpWorkerRequest.
Modified:
branches/mainsoft/gh2.2/mcs/class/System.Web/System.Web/HttpRequest.jvm.cs
===================================================================
--- branches/mainsoft/gh2.2/mcs/class/System.Web/System.Web/HttpRequest.jvm.cs
2008-02-12 14:25:37 UTC (rev 95501)
+++ branches/mainsoft/gh2.2/mcs/class/System.Web/System.Web/HttpRequest.jvm.cs
2008-02-12 14:30:39 UTC (rev 95502)
@@ -138,10 +138,8 @@
{
if (context == null)
return;
- HttpServletRequest servletReq = context.ServletRequest;
- if (servletReq == null)
- return;
- HttpSession javaSession = servletReq.getSession(false);
+ IHttpExtendedWorkerRequest exWorker =
(IHttpExtendedWorkerRequest) context.WorkerRequest;
+ HttpSession javaSession = exWorker.GetSession (false);
if (javaSession == null)
return;
@@ -179,15 +177,13 @@
if (cookies == null || cookies.Count == 0)
return;
- HttpServletRequest servletReq = context.ServletRequest;
- if (servletReq == null)
- return;
- bool inPortletMode = true; //servletReq is
IPortletRequest;
+ IHttpExtendedWorkerRequest exWorker =
(IHttpExtendedWorkerRequest) context.WorkerRequest;
+ bool inPortletMode = !context.IsServletRequest;
bool shouldStoreCookiesCollection = false;
- HttpSession javaSession = servletReq.getSession(false);
+ HttpSession javaSession = exWorker.GetSession (false);
if (javaSession == null && inPortletMode)
- javaSession = servletReq.getSession(true);
+ javaSession = exWorker.GetSession (true);
if (javaSession == null)
return;
Added:
branches/mainsoft/gh2.2/mcs/class/System.Web/System.Web/IHttpExtendedWorkerRequest.cs
===================================================================
---
branches/mainsoft/gh2.2/mcs/class/System.Web/System.Web/IHttpExtendedWorkerRequest.cs
2008-02-12 14:25:37 UTC (rev 95501)
+++
branches/mainsoft/gh2.2/mcs/class/System.Web/System.Web/IHttpExtendedWorkerRequest.cs
2008-02-12 14:30:39 UTC (rev 95502)
@@ -0,0 +1,37 @@
+//
+// (C) 2007 Mainsoft Corporation (http://www.mainsoft.com)
+//
+
+//
+// Permission is hereby granted, free of charge, to any person obtaining
+// a copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to
+// permit persons to whom the Software is furnished to do so, subject to
+// the following conditions:
+//
+// The above copyright notice and this permission notice shall be
+// included in all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+//
+
+using System;
+using System.Collections.Generic;
+using System.Text;
+using javax.servlet.http;
+
+namespace System.Web
+{
+ public interface IHttpExtendedWorkerRequest
+ {
+ HttpSession GetSession (bool create);
+ }
+}
Modified:
branches/mainsoft/gh2.2/mcs/class/System.Web/System.Web.Phantom/System.Web.Phantom.csproj
===================================================================
---
branches/mainsoft/gh2.2/mcs/class/System.Web/System.Web.Phantom/System.Web.Phantom.csproj
2008-02-12 14:25:37 UTC (rev 95501)
+++
branches/mainsoft/gh2.2/mcs/class/System.Web/System.Web.Phantom/System.Web.Phantom.csproj
2008-02-12 14:30:39 UTC (rev 95502)
@@ -50,9 +50,13 @@
<Compile Include="..\System.Web\IHttpExtendedHandler.cs">
<Link>IHttpExtendedHandler.cs</Link>
</Compile>
+ <Compile Include="..\System.Web\IHttpExtendedWorkerRequest.cs">
+ <Link>IHttpExtendedWorkerRequest.cs</Link>
+ </Compile>
<Compile Include="Stubs.cs" />
</ItemGroup>
<ItemGroup>
+ <Reference Include="JavaEE, Version=0.0.0.0, Culture=neutral,
processorArchitecture=MSIL" />
<Reference Include="System, Version=2.0.0.0, Culture=neutral,
PublicKeyToken=b77a5c561934e089, processorArchitecture=MSIL" />
<Reference Include="System.Data, Version=2.0.0.0, Culture=neutral,
PublicKeyToken=b77a5c561934e089, processorArchitecture=x86" />
<Reference Include="System.Web, Version=2.0.0.0, Culture=neutral,
PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=x86" />
@@ -69,7 +73,7 @@
-->
<ProjectExtensions>
<VisualStudio>
- <UserProperties REFS-RefInfo-system-web="repository:vmw:framework:2.0"
REFS-JarPath-system-web="" REFS-RefInfo-rt="repository:jre:sun:1.6.0"
REFS-JarPath-rt="" REFS-RefInfo-system-xml="repository:vmw:framework:2.0"
REFS-JarPath-system-xml=""
REFS-RefInfo-system-data="repository:vmw:framework:2.0"
REFS-JarPath-system-data="" REFS-RefInfo-system="repository:vmw:framework:2.0"
REFS-JarPath-system="" />
+ <UserProperties REFS-RefInfo-javaee="repository:JavaEE:tomcat:1.3"
REFS-JarPath-javaee="" REFS-JarPath-system=""
REFS-RefInfo-system="repository:vmw:framework:2.0" REFS-JarPath-system-data=""
REFS-RefInfo-system-data="repository:vmw:framework:2.0"
REFS-JarPath-system-xml=""
REFS-RefInfo-system-xml="repository:vmw:framework:2.0" REFS-JarPath-rt=""
REFS-RefInfo-rt="repository:jre:sun:1.6.0" REFS-JarPath-system-web=""
REFS-RefInfo-system-web="repository:vmw:framework:2.0" />
</VisualStudio>
</ProjectExtensions>
-</Project>
+</Project>
\ No newline at end of file
Modified: branches/mainsoft/gh2.2/mcs/class/System.Web/System.Web20.csproj
===================================================================
--- branches/mainsoft/gh2.2/mcs/class/System.Web/System.Web20.csproj
2008-02-12 14:25:37 UTC (rev 95501)
+++ branches/mainsoft/gh2.2/mcs/class/System.Web/System.Web20.csproj
2008-02-12 14:30:39 UTC (rev 95502)
@@ -1,4 +1,4 @@
-<Project DefaultTargets="Build"
xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+<Project DefaultTargets="Build"
xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == ''
">Debug_Java</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
@@ -1281,6 +1281,7 @@
<SubType>Code</SubType>
</Compile>
<Compile Include="System.Web\HttpWorkerRequest.jvm.cs" />
+ <Compile Include="System.Web\IHttpExtendedWorkerRequest.cs" />
<Compile Include="System.Web\RequestNotification.cs" />
<Compile Include="System.Web\RequestNotificationStatus.cs" />
<Compile Include="System.Web\UplevelHelper.cs" />
@@ -1456,4 +1457,4 @@
<PropertyGroup>
<PreBuildEvent>"$(ProjectDir)..\..\class\lib\net_2_0\culevel.exe" -o
"$(ProjectDir)System.Web\UplevelHelper.cs"
"$(ProjectDir)UplevelHelperDefinitions.xml"</PreBuildEvent>
</PropertyGroup>
-</Project>
\ No newline at end of file
+</Project>
_______________________________________________
Mono-patches maillist - [email protected]
http://lists.ximian.com/mailman/listinfo/mono-patches