match requests with empty (or null) catch-all portion.
Included a couple of unit-tests which pass both here, and on ms.net land.
License: This patch is under MIT/X11 license.
This patch fixes some inconsistencies on Sys.Web.Routing between our implementation
and the one found on MS.NET.. Both relating to URL Generation code inside of
Route.GetVirtualPath().
1) When defining a route with a parameter with both a default value and some
constraint, Route.GetVirtualPath() fails to match if no parameter values is specified.
2) HttpMethodConstraint, does not take into account RouteDirection.UrlGeneration.
See: https://bugzilla.xamarin.com/show_bug.cgi?id=8646
License: This patch is under MIT/X11 license.
* PageRouteHandler.cs: implemented
2010-06-05 Marek Habersack <[email protected]>
* UrlRoutingModule.cs: 4.0 doesn't do the UrlRouting.axd magic, it
simply remaps the current handler to the one obtained from the
route.
2010-06-05 Marek Habersack <[email protected]>
* TemplateControlCompiler.cs: expression evaluation results are
wrapped in a Convert.ConvertTo* call or a typecast.
* RouteValueExpressionBuilder.cs: implemented
* RouteUrlExpressionBuilder.cs: added missing custom attributes
svn path=/trunk/mcs/; revision=158497
* HttpResponse.cs: implemented the following 4.0 methods:
RedirectPermanent, RedirectToRoute, RedirectToRoutePermanent and
RemoveOutputCacheItem.
2010-05-06 Marek Habersack <[email protected]>
* RouteCollection.cs: GetVirtualPath throws ArgumentException
when named route is not found in the collection.
2010-05-06 Marek Habersack <[email protected]>
* OutputCacheModule.cs: added a 2.0 internal property to return
the internal provider used in this profile.
* OutputCache.cs: added internal RemoveFromProvider method to
remove items from the indicated provider.
svn path=/trunk/mcs/; revision=156933
* RouteValueDictionary.cs: do not process type fields in
RouteValueDictionary (object)
* RouteCollection.cs: GetRouteData throws an exception if Request
is null in the passed context.
Added Ignore* and MapPageRoute* 4.0 APIs
* RequestContext.cs: 4.0 API update
* PatternParser.cs: match parser rewrite to encompass 4.0 bug
fixes. We don't emulate some of the pre-4.0 routing bugs anymore.
svn path=/trunk/mcs/; revision=156695
* HttpRequest.cs: PathInfo returns an empty string when worker
request is absent or its GetPathInfo method returns a null. Patch
from Tiaan <[email protected]>, thanks!
2009-11-23 Marek Habersack <[email protected]>
* Route.cs: GetRouteData throws NotImplementedException only when
pathInfo for the current request is a non-empty string. Patch from
Tiaan <[email protected]>, thanks!
svn path=/trunk/mcs/; revision=146732
* RouteTest.cs: added two tests for empty and null route URLs (bug
#537751)
2009-09-09 Marek Habersack <[email protected]>
* Route.cs: when Url is set to null, create a parser for empty
string. Fixes bug #537751
* PatternParser.cs: Parse allows for null/empty URLs. Fixes bug
#537751
svn path=/trunk/mcs/; revision=141630
* UrlRoutingModule.cs: store original request path in
PostResolveRequestCache and restore it in
PostMapRequestHandler. Fixes bug #537089
svn path=/trunk/mcs/; revision=141471
* Route.cs: GetRouteData adds contents of its DataTokens
dictionary to the returned RouteData.DataTokens dictionary. Fixes
bug #523330. Patch from [email protected], thanks!
svn path=/trunk/mcs/; revision=140273
* RouteCollectionTest.cs, RouteTest.cs: added new tests for
GetVirtualPath
2009-06-25 Marek Habersack <[email protected]>
* PatternParser.cs: parameter name lookups must be
case-insensitive.
Null and empty (string) parameters are skipped when building query
part of the action path.
2009-06-25 Marek Habersack <[email protected]>
* LinqDataSource.cs: make ContextType not throw an exception when
ContextTypeName is not set, but rather return a null in that
case.
2009-06-25 Marek Habersack <[email protected]>
* MetaTableTest.cs: new GetVirtualPath tests.
* DynamicDataRouteTest.cs: added tests for route.Defaults
modifications on class init.
* DynamicDataRouteHandlerTest.cs: added
2009-06-25 Marek Habersack <[email protected]>
* MetaTable.cs: Fixes to make tests succeed.
* MetaModel.cs: added the GetDataFieldAttributes method for
retrieving attributes associated with data type/field.
Fixes to make tests succeed.
* MetaColumn.cs: refactoring - use
MetaModel.GetDataFieldAttributes instead of the local version.
* DynamicDataRouteHandler.cs: implemented GetRequestContext,
GetRequestMetaTable.
* DynamicDataRoute.cs: when the Action and Table properties are
set before one of GetVirtualPath or GetRouteData methods are
called for the first time, a check is made whether the Defaults
collection exists and whether it contains entries for Action and
Table. Initialization code makes sure those entries are inserted
into the dictionary in those cases.
svn path=/trunk/mcs/; revision=136875
* RouteValueDictionaryExtensions.cs: do not compile if
SYSTEMCORE_DEP is not defined
* PatternParser.cs: if SYSTEMCORE_DEP is not defined, do not
compile parts which require RouteValueDictionaryExtensions.
2009-06-16 Marek Habersack <[email protected]>
* Makefile (LIB_MCS_FLAGS): define SYSTEMCORE_DEP
2009-06-16 Marek Habersack <[email protected]>
* DynamicDataManager.cs, DynamicDataExtensions.cs: use new
DataBoundControl.DataSourceObject instead of
InternalGetDataSource
2009-06-16 Marek Habersack <[email protected]>
* Makefile: warn if the 4.0 assembly is compiled without
System.Core
svn path=/trunk/mcs/; revision=136222
* net_4_0_System.Web.Routing.dll.sources: added. In the 4.0
profile all classes are compiled into System.Web,
System.Web.Routing becomes an empty assembly.
2009-06-16 Marek Habersack <[email protected]>
* net_4_0_System.Web.Abstractions.dll.sources: added. In the 4.0
profile all classes are compiled into System.Web,
System.Web.Abstractions becomes an empty assembly.
2009-06-16 Marek Habersack <[email protected]>
* Decorated all classes with the TypeForwardedFrom attribute for
the 4.0 profile.
2009-06-16 Marek Habersack <[email protected]>
* Decorated all classes with the TypeForwardedFrom attribute for
the 4.0 profile.
2009-06-16 Marek Habersack <[email protected]>
* net_4_0_System.Web.dll.sources: added. System.Web.Routing and
System.Web.Abstractions are part of System.Web.dll in the 4.0
profile.
svn path=/trunk/mcs/; revision=136182
* RouteValueDictionaryExtensions.cs: if both values are strings in
Has (string, value), compare them case-insensitively. Fixes bug
#502555
2009-06-04 Marek Habersack <[email protected]>
* RouteCollectionTest.cs: added two more test cases to the bug
#502555 test. They check whether url generation matches defaults
case-insensitively.
svn path=/trunk/mcs/; revision=135438
* Makefile (LIB_MCS_FLAGS): added support for defining the DEBUG
symbol on compiler command line.
2009-05-27 Marek Habersack <[email protected]>
* PatternParser.cs: if Match is passed an empty path, do not
attempt to match the Url segments, skip to defaults matching right
away.
2009-05-27 Marek Habersack <[email protected]>
* RouteCollectionTest.cs: added a test for routes from
NerdDinner.
svn path=/trunk/mcs/; revision=134877