Class ImageVaultCoreProxy
base class for a proxy handler that communicates with core
Inheritance
System.Object
ImageVaultCoreProxy
Implements
System.Web.IHttpHandler
System.Web.Routing.IRouteHandler
Inherited Members
System.Object.ToString()
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
Assembly: ImageVault.Client.dll
Syntax
public abstract class ImageVaultCoreProxy : RouteHandlerBase
Constructors
ImageVaultCoreProxy(String)
Declaration
protected ImageVaultCoreProxy(string path)
Parameters
| Type |
Name |
Description |
| System.String |
path |
|
Fields
Name of header that contains the original url for the proxy request
Declaration
public const string XForwardedUrlHeaderName = "X-Forwarded-Url"
Field Value
| Type |
Description |
| System.String |
|
Properties
HttpWebRequestFactory
Declaration
public IHttpWebRequestFactory HttpWebRequestFactory { get; set; }
Property Value
Methods
If special handling using request header copying should occur, this method can be implemented
Declaration
protected virtual bool CopyRequestHeaders(string name, string value, IHttpWebRequest dest)
Parameters
| Type |
Name |
Description |
| System.String |
name |
The request header name to copy
|
| System.String |
value |
The request header value to copy
|
| IHttpWebRequest |
dest |
The destination request to copy (or not) the header to
|
Returns
| Type |
Description |
| System.Boolean |
True if copy was handled, false if copy wasn't handled and normal copy rules should occur.
|
Declaration
protected virtual void CopyRequestHeaders(HttpRequestBase source, IHttpWebRequest dest, bool forceNewAuthToken)
Parameters
| Type |
Name |
Description |
| System.Web.HttpRequestBase |
source |
|
| IHttpWebRequest |
dest |
|
| System.Boolean |
forceNewAuthToken |
|
Declaration
protected virtual bool CopyResponseHeader(string name, string value, HttpResponseBase dest)
Parameters
| Type |
Name |
Description |
| System.String |
name |
|
| System.String |
value |
|
| System.Web.HttpResponseBase |
dest |
|
Returns
| Type |
Description |
| System.Boolean |
|
Declaration
protected virtual void CopyResponseHeaders(IHttpWebResponse source, HttpResponseBase dest)
Parameters
GetAuthorizationValue(HttpRequestBase, Boolean)
Retrieves the authorization value for the Authorization header for the real request.
Declaration
protected virtual string GetAuthorizationValue(HttpRequestBase request, bool forceNewAuthToken)
Parameters
| Type |
Name |
Description |
| System.Web.HttpRequestBase |
request |
|
| System.Boolean |
forceNewAuthToken |
If a new token should be forced
|
Returns
| Type |
Description |
| System.String |
|
GetCoreUrl(HttpContextBase)
Gets the core url where the real request should be headed.
Declaration
protected virtual string GetCoreUrl(HttpContextBase context)
Parameters
| Type |
Name |
Description |
| System.Web.HttpContextBase |
context |
|
Returns
| Type |
Description |
| System.String |
|
GetQuery(HttpContextBase)
Gets the query part for the real request
Declaration
protected virtual string GetQuery(HttpContextBase context)
Parameters
| Type |
Name |
Description |
| System.Web.HttpContextBase |
context |
|
Returns
| Type |
Description |
| System.String |
|
GetRealUri(HttpContextBase)
Gets the real uri for the request
Declaration
protected Uri GetRealUri(HttpContextBase context)
Parameters
| Type |
Name |
Description |
| System.Web.HttpContextBase |
context |
|
Returns
| Type |
Description |
| System.Uri |
|
PerformRealRequest(HttpContextBase, Uri, String, Boolean)
Declaration
protected void PerformRealRequest(HttpContextBase context, Uri location, string content, bool forceNewAuthToken = false)
Parameters
| Type |
Name |
Description |
| System.Web.HttpContextBase |
context |
|
| System.Uri |
location |
|
| System.String |
content |
|
| System.Boolean |
forceNewAuthToken |
|
Exceptions
| Type |
Condition |
| System.ApplicationException |
If cannot create request for .
|
Implements
System.Web.IHttpHandler
System.Web.Routing.IRouteHandler
Extension Methods