#89 - Rename OnRequestAborted to RequestAborted.

This commit is contained in:
Chris Ross 2014-07-01 16:24:27 -07:00
parent 05a275faae
commit bc2cf1223e
6 changed files with 7 additions and 7 deletions

View File

@ -26,7 +26,7 @@ namespace Microsoft.AspNet.Http
public abstract IServiceProvider RequestServices { get; set; } public abstract IServiceProvider RequestServices { get; set; }
public abstract CancellationToken OnRequestAborted { get; } public abstract CancellationToken RequestAborted { get; }
public abstract bool IsWebSocketRequest { get; } public abstract bool IsWebSocketRequest { get; }

View File

@ -9,7 +9,7 @@ namespace Microsoft.AspNet.HttpFeature
[AssemblyNeutral] [AssemblyNeutral]
public interface IHttpRequestLifetimeFeature public interface IHttpRequestLifetimeFeature
{ {
CancellationToken OnRequestAborted { get; } CancellationToken RequestAborted { get; }
void Abort(); void Abort();
} }
} }

View File

@ -31,7 +31,7 @@ namespace Microsoft.AspNet.Owin
_context = context; _context = context;
_entries = new Dictionary<string, FeatureMap>() _entries = new Dictionary<string, FeatureMap>()
{ {
{ OwinConstants.CallCancelled, new FeatureMap<IHttpRequestLifetimeFeature>(feature => feature.OnRequestAborted) }, { OwinConstants.CallCancelled, new FeatureMap<IHttpRequestLifetimeFeature>(feature => feature.RequestAborted) },
{ OwinConstants.RequestProtocol, new FeatureMap<IHttpRequestFeature>(feature => feature.Protocol, (feature, value) => feature.Protocol = Convert.ToString(value)) }, { OwinConstants.RequestProtocol, new FeatureMap<IHttpRequestFeature>(feature => feature.Protocol, (feature, value) => feature.Protocol = Convert.ToString(value)) },
{ OwinConstants.RequestScheme, new FeatureMap<IHttpRequestFeature>(feature => feature.Scheme, (feature, value) => feature.Scheme = Convert.ToString(value)) }, { OwinConstants.RequestScheme, new FeatureMap<IHttpRequestFeature>(feature => feature.Scheme, (feature, value) => feature.Scheme = Convert.ToString(value)) },
{ OwinConstants.RequestMethod, new FeatureMap<IHttpRequestFeature>(feature => feature.Method, (feature, value) => feature.Method = Convert.ToString(value)) }, { OwinConstants.RequestMethod, new FeatureMap<IHttpRequestFeature>(feature => feature.Method, (feature, value) => feature.Method = Convert.ToString(value)) },

View File

@ -218,7 +218,7 @@ namespace Microsoft.AspNet.Owin
return Prop<X509Certificate>(OwinConstants.CommonKeys.ClientCertificate); return Prop<X509Certificate>(OwinConstants.CommonKeys.ClientCertificate);
} }
CancellationToken IHttpRequestLifetimeFeature.OnRequestAborted CancellationToken IHttpRequestLifetimeFeature.RequestAborted
{ {
get { return Prop<CancellationToken>(OwinConstants.CallCancelled); } get { return Prop<CancellationToken>(OwinConstants.CallCancelled); }
} }

View File

@ -109,14 +109,14 @@ namespace Microsoft.AspNet.PipelineCore
public int Revision { get { return _features.Revision; } } public int Revision { get { return _features.Revision; } }
public override CancellationToken OnRequestAborted public override CancellationToken RequestAborted
{ {
get get
{ {
var lifetime = LifetimeFeature; var lifetime = LifetimeFeature;
if (lifetime != null) if (lifetime != null)
{ {
return lifetime.OnRequestAborted; return lifetime.RequestAborted;
} }
return CancellationToken.None; return CancellationToken.None;
} }

View File

@ -155,7 +155,7 @@ namespace Microsoft.AspNet.Owin
private class MoqHttpRequestLifetimeFeature : IHttpRequestLifetimeFeature private class MoqHttpRequestLifetimeFeature : IHttpRequestLifetimeFeature
{ {
public CancellationToken OnRequestAborted { get; private set; } public CancellationToken RequestAborted { get; private set; }
public void Abort() public void Abort()
{ {