C# Класс CorsProxy.AspNet.CorsProxyRoute

Our route implementation which uses the CorsProxyHttpHandler.
Наследование: System.Web.Routing.Route
Показать файл Открыть проект Примеры использования класса

Открытые методы

Метод Описание
Allow ( Uri targetUri ) : void

Allow this host

Used to only allow all specified hosts (calls to this method can be chained).

CorsProxyRoute ( string url ) : System

Initializes a new instance of the T:System.Web.Routing.Route class, by using the specified URL pattern and handler class.

GetRouteData ( System.Web.HttpContextBase httpContext ) : System.Web.Routing.RouteData
GetVirtualPath ( System.Web.Routing.RequestContext requestContext, RouteValueDictionary values ) : System.Web.Routing.VirtualPathData

Returns information about the URL that is associated with the route.

Приватные методы

Метод Описание
SameHostAndPort ( Uri url1, Uri url ) : bool

Описание методов

Allow() публичный Метод

Allow this host
Used to only allow all specified hosts (calls to this method can be chained).
userHostAddress
public Allow ( Uri targetUri ) : void
targetUri System.Uri Uri which proxying is allowed to. Typically your back-end URI.
Результат void

CorsProxyRoute() публичный Метод

Initializes a new instance of the T:System.Web.Routing.Route class, by using the specified URL pattern and handler class.
public CorsProxyRoute ( string url ) : System
url string The URL pattern for the route.
Результат System

GetRouteData() публичный Метод

public GetRouteData ( System.Web.HttpContextBase httpContext ) : System.Web.Routing.RouteData
httpContext System.Web.HttpContextBase
Результат System.Web.Routing.RouteData

GetVirtualPath() публичный Метод

Returns information about the URL that is associated with the route.
public GetVirtualPath ( System.Web.Routing.RequestContext requestContext, RouteValueDictionary values ) : System.Web.Routing.VirtualPathData
requestContext System.Web.Routing.RequestContext An object that encapsulates information about the requested route.
values RouteValueDictionary An object that contains the parameters for a route.
Результат System.Web.Routing.VirtualPathData