302 references to HttpStatusCode
PresentationCore (1)
Core\CSharp\MS\Internal\IO\Packaging\ByteRangeDownloader.cs (1)
603
if (webResponse.StatusCode ==
HttpStatusCode
.PartialContent)
System (102)
net\System\Net\_AuthenticationState.cs (4)
80
internal
HttpStatusCode
StatusCodeMatch {
82
return IsProxyAuth ?
HttpStatusCode
.ProxyAuthenticationRequired :
HttpStatusCode
.Unauthorized;
355
if (!IsProxyAuth && httpWebRequest.ResponseStatusCode==
HttpStatusCode
.ProxyAuthenticationRequired) {
net\System\Net\_Connection.cs (11)
2144
m_ResponseData.m_StatusCode = (
HttpStatusCode
) m_StatusLineValues.StatusCode;
2222
dummyResponseStream = !request.CanGetResponseStream || m_ResponseData.m_StatusCode <
HttpStatusCode
.OK ||
2223
m_ResponseData.m_StatusCode ==
HttpStatusCode
.NoContent || (m_ResponseData.m_StatusCode ==
HttpStatusCode
.NotModified && contentLength < 0) ;
2249
else if (m_ResponseData.m_StatusCode ==
HttpStatusCode
.Forbidden && NetworkStream is TlsStream)
2428
if (m_CurrentRequest.IsWebSocketRequest && m_ResponseData.m_StatusCode ==
HttpStatusCode
.SwitchingProtocols)
2692
if(m_IISVersion == -1 && m_ResponseData.m_StatusCode !=
HttpStatusCode
.Continue){
2701
if (m_ResponseData.m_StatusCode ==
HttpStatusCode
.Continue || m_ResponseData.m_StatusCode ==
HttpStatusCode
.BadRequest || isUnknownInterimResponse) {
2706
if (m_ResponseData.m_StatusCode ==
HttpStatusCode
.BadRequest) {
2722
if (m_ResponseData.m_StatusCode ==
HttpStatusCode
.Continue)
net\System\Net\_NetRes.cs (1)
81
public static string GetWebStatusCodeString(
HttpStatusCode
statusCode, string statusDescription) {
net\System\Net\Cache\_Rfc2616CacheValidators.cs (28)
234
if (ctx.RequestRangeCache && resp.StatusCode ==
HttpStatusCode
.RequestedRangeNotSatisfiable) {
242
if (resp.StatusCode ==
HttpStatusCode
.NotModified)
310
if (ctx.CacheStatusCode ==
HttpStatusCode
.NotModified) {
357
if (resp.StatusCode ==
HttpStatusCode
.NotModified || ctx.RequestMethod == HttpMethod.Head)
380
else if (resp.StatusCode ==
HttpStatusCode
.PartialContent)
683
if(resp.StatusCode ==
HttpStatusCode
.NotModified) {
842
if (resp.StatusCode ==
HttpStatusCode
.NotModified ||
843
resp.StatusCode ==
HttpStatusCode
.OK ||
844
resp.StatusCode ==
HttpStatusCode
.NonAuthoritativeInformation ||
845
resp.StatusCode ==
HttpStatusCode
.PartialContent ||
846
resp.StatusCode ==
HttpStatusCode
.MultipleChoices ||
847
resp.StatusCode ==
HttpStatusCode
.MovedPermanently ||
848
resp.StatusCode ==
HttpStatusCode
.Gone)
1046
if ((ctx.CacheStream == Stream.Null || (int)ctx.CacheStatusCode == 0) && resp.StatusCode ==
HttpStatusCode
.NotModified) {
1075
if (resp.StatusCode !=
HttpStatusCode
.NotModified && resp.Headers.LastModified != ctx.CacheHeaders.LastModified)
1087
if (resp.StatusCode ==
HttpStatusCode
.PartialContent) {
1134
ctx.CacheStatusCode =
HttpStatusCode
.OK;
1169
if (resp.StatusCode ==
HttpStatusCode
.NotModified) {
1272
if (ctx.CacheStream == Stream.Null || ctx.CacheStatusCode == (
HttpStatusCode
)0) {
1276
if (ctx.CacheEntityLength != ctx.CacheEntry.StreamSize || ctx.CacheStatusCode ==
HttpStatusCode
.PartialContent) {
1543
if (ctx.CacheStatusCode ==
HttpStatusCode
.PartialContent && ctx.CacheEntityLength == ctx.CacheEntry.StreamSize)
1546
ctx.CacheStatusCode =
HttpStatusCode
.OK;
1550
if (ctx.CacheEntry.IsPartialEntry || (ctx.CacheEntityLength != -1 && ctx.CacheEntityLength != ctx.CacheEntry.StreamSize) || ctx.CacheStatusCode ==
HttpStatusCode
.PartialContent)
1704
ctx.CacheStatusCode =
HttpStatusCode
.PartialContent;
1718
ctx.CacheStatusCode =
HttpStatusCode
.OK;
1771
if (ctx.CacheHeaders == null || (resp.StatusCode !=
HttpStatusCode
.NotModified && resp.StatusCode !=
HttpStatusCode
.PartialContent))
1831
if (resp.StatusCode ==
HttpStatusCode
.NotModified && AsciiLettersNoCaseEqual(key, HttpKnownHeaderNames.ContentLength)) {
net\System\Net\Cache\HttpRequestCacheValidator.cs (12)
51
private
HttpStatusCode
m_StatusCode;
87
internal
HttpStatusCode
CacheStatusCode {get{return m_StatusCode;} set{m_StatusCode = value;}}
145
m_StatusCode = (
HttpStatusCode
)0;
258
if (CacheStream == Stream.Null || (int)CacheStatusCode == 0 || CacheStatusCode ==
HttpStatusCode
.NotModified)
312
CacheStatusCode = (
HttpStatusCode
) 0;
334
if (CacheStream == Stream.Null || (int)CacheStatusCode == 0 || CacheStatusCode ==
HttpStatusCode
.NotModified)
354
if (resp.StatusCode >=
HttpStatusCode
.InternalServerError) {
423
(resp.StatusCode ==
HttpStatusCode
.PartialContent
571
CacheStatusCode = (
HttpStatusCode
)0;
629
CacheStatusCode = (
HttpStatusCode
)status;
779
if ((forCache? CacheStatusCode: resp.StatusCode) !=
HttpStatusCode
.PartialContent) {
809
CacheStatusCode =
HttpStatusCode
.OK;
net\System\Net\HttpListener.cs (19)
1242
SendError(requestMemory.RequestBlob->RequestId,
HttpStatusCode
.BadRequest, null);
1422
SendError(requestId,
HttpStatusCode
.InternalServerError, null);
1493
HttpStatusCode
httpError =
HttpStatusCode
.InternalServerError;
1512
httpError =
HttpStatusCode
.Unauthorized;
1579
httpError =
HttpStatusCode
.Unauthorized;
1593
httpError =
HttpStatusCode
.Unauthorized;
1646
httpError =
HttpStatusCode
.BadRequest;
1679
httpError =
HttpStatusCode
.Unauthorized;
1762
httpError =
HttpStatusCode
.BadRequest;
1818
if (httpError !=
HttpStatusCode
.Unauthorized)
1858
SendError(requestId,
HttpStatusCode
.InternalServerError, null);
1896
SendError(requestId, challenges != null && challenges.Count > 0 ?
HttpStatusCode
.Unauthorized :
HttpStatusCode
.Forbidden, challenges);
2323
private void SendError(ulong requestId,
HttpStatusCode
httpStatusCode, ArrayList challenges)
2518
private
HttpStatusCode
HttpStatusFromSecurityStatus(SecurityStatus status)
2522
return
HttpStatusCode
.Unauthorized;
2526
return
HttpStatusCode
.BadRequest;
2528
return
HttpStatusCode
.InternalServerError;
net\System\Net\HttpListenerResponse.cs (3)
46
m_NativeResponse.StatusCode = (ushort)
HttpStatusCode
.OK;
276
StatusCode = (int)
HttpStatusCode
.Redirect;
481
if (StatusCode == (int)
HttpStatusCode
.Unauthorized) { // User set 401
net\System\Net\HttpStatusDescription.cs (1)
88
internal static string Get(
HttpStatusCode
code)
net\System\Net\HttpWebRequest.cs (16)
106
internal const
HttpStatusCode
MaxOkStatus = (
HttpStatusCode
)299;
107
private const
HttpStatusCode
MaxRedirectionStatus = (
HttpStatusCode
)399;
868
internal
HttpStatusCode
ResponseStatusCode {
5641
if (ResponseStatusCode==
HttpStatusCode
.Unauthorized || // 401
5642
ResponseStatusCode==
HttpStatusCode
.ProxyAuthenticationRequired) // 407
5694
if (ResponseStatusCode ==
HttpStatusCode
.BadRequest && this.SendChunked
5717
ResponseStatusCode==
HttpStatusCode
.Ambiguous || // 300
5718
ResponseStatusCode==
HttpStatusCode
.Moved || // 301
5719
ResponseStatusCode==
HttpStatusCode
.Redirect || // 302
5720
ResponseStatusCode==
HttpStatusCode
.RedirectMethod || // 303
5721
ResponseStatusCode==
HttpStatusCode
.RedirectKeepVerb )) // 307
5811
case
HttpStatusCode
.Moved:
5812
case
HttpStatusCode
.Redirect:
5817
case
HttpStatusCode
.RedirectKeepVerb:
net\System\Net\HttpWebResponse.cs (4)
37
private
HttpStatusCode
m_StatusCode;
300
public virtual
HttpStatusCode
StatusCode {
411
if (m_IsWebSocketResponse && m_StatusCode ==
HttpStatusCode
.SwitchingProtocols) // HTTP 101
582
m_StatusCode = (
HttpStatusCode
)serializationInfo.GetInt32("m_StatusCode");
net\System\Net\Internal.cs (1)
1752
public
HttpStatusCode
m_StatusCode;
net\System\Net\WebSockets\ClientWebSocket.cs (1)
263
if (response.StatusCode !=
HttpStatusCode
.SwitchingProtocols)
net\System\Net\WebSockets\WebSocketHelpers.cs (1)
114
response.StatusCode = (int)
HttpStatusCode
.SwitchingProtocols; // HTTP 101
System.Data.Services (9)
System\Data\Services\ErrorHandler.cs (2)
231
if (dataServiceException.StatusCode == (int)System.Net.
HttpStatusCode
.NotModified)
235
host.ResponseStatusCode = (int)System.Net.
HttpStatusCode
.NotModified;
System\Data\Services\HttpContextServiceHost.cs (6)
260
HttpStatusCode
statusCode = (
HttpStatusCode
)value;
515
private static bool MustNotReturnMessageBody(
HttpStatusCode
statusCode)
520
case
HttpStatusCode
.NoContent: // 204
521
case
HttpStatusCode
.ResetContent: // 205
522
case
HttpStatusCode
.NotModified: // 304
System\Data\Services\Providers\DataServiceStreamProviderWrapper.cs (1)
167
if (e.StatusCode == (int)System.Net.
HttpStatusCode
.NotModified)
System.Data.Services.Client (22)
System\Data\Services\Client\BatchStream.cs (2)
363
internal
HttpStatusCode
GetStatusCode()
365
return (
HttpStatusCode
)(null != this.statusCode ? Int32.Parse(this.statusCode, CultureInfo.InvariantCulture) : 500);
System\Data\Services\Client\DataServiceContext.cs (10)
1648
HttpStatusCode
statusCode,
1684
internal static DataServiceClientException GetResponseText(Func<Stream> getResponseStream,
HttpStatusCode
statusCode)
2609
writer.WriteLine("{0} {1} {2}", XmlConstants.HttpVersionInBatching, statusCode, (
HttpStatusCode
)statusCode);
4979
else if (response.StatusCode ==
HttpStatusCode
.Created)
5281
if ((null == this.batchResponse) || (
HttpStatusCode
.NoContent == this.batchResponse.StatusCode))
5366
int statusCode = this.batchResponse == null ? (int)
HttpStatusCode
.InternalServerError : (int)this.batchResponse.StatusCode;
5395
HttpStatusCode
status;
5431
status = (
HttpStatusCode
)(-1);
5467
if (this.Context.ignoreResourceNotFoundException && status ==
HttpStatusCode
.NotFound)
5498
HttpStatusCode
statusCode = batch.GetStatusCode();
System\Data\Services\Client\DataServiceRequest.cs (4)
136
if (context.IgnoreResourceNotFoundException && serviceEx != null && serviceEx.StatusCode == (int)
HttpStatusCode
.NotFound)
139
qor.StatusCode = (int)
HttpStatusCode
.NotFound;
174
if (cex != null && cex.StatusCode == (int)
HttpStatusCode
.NotFound)
210
if (
HttpStatusCode
.NoContent != response.StatusCode)
System\Data\Services\Client\QueryResult.cs (5)
63
private
HttpStatusCode
statusCode;
113
internal
HttpStatusCode
StatusCode
233
if (
HttpStatusCode
.NoContent != this.StatusCode)
329
if (
HttpStatusCode
.NoContent != this.StatusCode)
571
if (
HttpStatusCode
.NoContent != response.StatusCode)
System\Data\Services\Client\WebUtil.cs (1)
102
internal static bool SuccessStatusCode(
HttpStatusCode
status)
System.Net (1)
AssemblyInfo.cs (1)
22
[assembly: TypeForwardedToAttribute(typeof(System.Net.
HttpStatusCode
))]
System.Runtime.Remoting (1)
channels\http\httpremotinghandler.cs (1)
300
context.Response.StatusCode = (int)
HttpStatusCode
.InternalServerError;
System.ServiceModel (97)
System\ServiceModel\Channels\ClientWebSocketTransportDuplexSessionChannel.cs (5)
208
if (webResponse.StatusCode ==
HttpStatusCode
.BadRequest)
224
else if (webResponse.StatusCode ==
HttpStatusCode
.UpgradeRequired)
432
if (response.StatusCode !=
HttpStatusCode
.SwitchingProtocols)
437
SR.WebSocketUpgradeFailedError, (int)response.StatusCode, response.StatusDescription, (int)
HttpStatusCode
.SwitchingProtocols,
HttpStatusCode
.SwitchingProtocols))));
System\ServiceModel\Channels\HttpChannelHelpers.cs (21)
142
ThrowHttpProtocolException(SR.GetString(SR.MaxReceivedMessageSizeExceeded, settings.MaxReceivedMessageSize),
HttpStatusCode
.RequestEntityTooLarge);
396
ThrowHttpProtocolException(SR.GetString(SR.HttpContentTypeHeaderRequired),
HttpStatusCode
.UnsupportedMediaType, HttpChannelUtilities.StatusDescriptionStrings.HttpContentTypeMissing);
410
ThrowHttpProtocolException(SR.GetString(SR.ContentTypeMismatch, ContentType, messageEncoder.ContentType),
HttpStatusCode
.UnsupportedMediaType, statusDescription);
590
void ThrowHttpProtocolException(string message,
HttpStatusCode
statusCode)
595
void ThrowHttpProtocolException(string message,
HttpStatusCode
statusCode, string statusDescription)
600
internal static ProtocolException CreateHttpProtocolException(string message,
HttpStatusCode
statusCode, string statusDescription, Exception innerException)
1192
protected abstract void SetStatusCode(
HttpStatusCode
statusCode);
2423
protected override void SetStatusCode(
HttpStatusCode
statusCode)
2920
this.SetStatusCode(
HttpStatusCode
.InternalServerError);
2924
this.SetStatusCode(
HttpStatusCode
.OK);
3066
protected override void SetStatusCode(
HttpStatusCode
statusCode)
3523
if (response.StatusCode ==
HttpStatusCode
.NotFound)
3528
if (response.StatusCode ==
HttpStatusCode
.ServiceUnavailable)
3533
if (response.StatusCode ==
HttpStatusCode
.UnsupportedMediaType)
3546
if (response.StatusCode ==
HttpStatusCode
.GatewayTimeout)
3554
if (response.StatusCode ==
HttpStatusCode
.BadRequest)
3611
if (response.StatusCode ==
HttpStatusCode
.InternalServerError &&
3780
if (response.StatusCode ==
HttpStatusCode
.Unauthorized)
3788
if (response.StatusCode ==
HttpStatusCode
.Forbidden)
3833
if ((200 <= (int)response.StatusCode && (int)response.StatusCode < 300) || response.StatusCode ==
HttpStatusCode
.InternalServerError)
3835
if (response.StatusCode ==
HttpStatusCode
.InternalServerError
System\ServiceModel\Channels\HttpChannelListener.cs (19)
661
HttpStatusCode
ValidateAuthentication(string authType)
665
return
HttpStatusCode
.OK;
672
string message = SR.GetString(SR.HttpAuthenticationFailed, this.AuthenticationScheme,
HttpStatusCode
.Unauthorized);
677
return
HttpStatusCode
.Unauthorized;
681
public virtual
HttpStatusCode
ValidateAuthentication(IHttpAuthenticationContext authenticationContext)
683
HttpStatusCode
result =
HttpStatusCode
.OK;
691
if (result ==
HttpStatusCode
.OK &&
701
result =
HttpStatusCode
.Unauthorized;
707
public virtual
HttpStatusCode
ValidateAuthentication(HttpListenerContext listenerContext)
709
HttpStatusCode
result =
HttpStatusCode
.OK;
1149
HttpStatusCode
statusCode =
HttpStatusCode
.BadRequest;
1153
statusCode = (
HttpStatusCode
)protocolException.Data[HttpChannelUtilities.HttpStatusCodeExceptionKey];
1168
context.SendResponseAndClose(
HttpStatusCode
.BadRequest);
1292
this.context.SendResponseAndClose(
HttpStatusCode
.BadRequest, SR.GetString(SR.WebSocketEndpointOnlySupportWebSocketError));
1298
this.context.SendResponseAndClose(
HttpStatusCode
.BadRequest, SR.GetString(SR.WebSocketEndpointDoesNotSupportWebSocketError));
1533
HttpResponseMessage response = new HttpResponseMessage(
HttpStatusCode
.InternalServerError);
System\ServiceModel\Channels\HttpPipeline.cs (8)
388
static readonly HttpResponseMessage internalServerErrorHttpResponseMessage = new HttpResponseMessage(
HttpStatusCode
.InternalServerError);
713
httpResponseMessage.StatusCode = message.IsFault ?
HttpStatusCode
.InternalServerError :
HttpStatusCode
.OK;
734
httpResponseMessage = new HttpResponseMessage(
HttpStatusCode
.Accepted);
798
if (response.StatusCode ==
HttpStatusCode
.SwitchingProtocols)
837
this.HttpRequestContext.SendResponseAndClose(
HttpStatusCode
.InternalServerError);
848
TD.WebSocketConnectionDeclined(this.EventTraceActivity,
HttpStatusCode
.ServiceUnavailable.ToString());
851
this.httpRequestContext.SendResponseAndClose(
HttpStatusCode
.ServiceUnavailable);
System\ServiceModel\Channels\HttpRequestContext.cs (11)
250
protected abstract
HttpStatusCode
ValidateAuthentication();
263
message = CreateAckMessage(
HttpStatusCode
.Accepted, string.Empty);
360
HttpStatusCode
statusCode = ValidateAuthentication();
362
if (statusCode ==
HttpStatusCode
.OK)
365
statusCode =
HttpStatusCode
.Forbidden;
381
if (e.Data[HttpChannelUtilities.HttpStatusCodeKey] is
HttpStatusCode
)
383
statusCode = (
HttpStatusCode
)e.Data[HttpChannelUtilities.HttpStatusCodeKey];
404
internal void SendResponseAndClose(
HttpStatusCode
statusCode)
409
internal void SendResponseAndClose(
HttpStatusCode
statusCode, string statusDescription)
465
Message CreateAckMessage(
HttpStatusCode
statusCode, string statusDescription)
856
protected override
HttpStatusCode
ValidateAuthentication()
System\ServiceModel\Channels\HttpResponseMessageProperty.cs (6)
52
public
HttpStatusCode
StatusCode
226
public const
HttpStatusCode
DefaultStatusCode =
HttpStatusCode
.OK;
231
HttpStatusCode
statusCode;
258
public
HttpStatusCode
StatusCode
307
public
HttpStatusCode
StatusCode
System\ServiceModel\Channels\HttpsChannelListener.cs (10)
30
const
HttpStatusCode
CertificateErrorStatusCode =
HttpStatusCode
.Forbidden;
303
public override
HttpStatusCode
ValidateAuthentication(IHttpAuthenticationContext authenticationContext)
305
HttpStatusCode
result = base.ValidateAuthentication(authenticationContext);
306
if (result ==
HttpStatusCode
.OK)
335
if (result !=
HttpStatusCode
.OK && (AuditLevel.Failure == (this.AuditBehavior.MessageAuthenticationAuditLevel & AuditLevel.Failure)))
349
public override
HttpStatusCode
ValidateAuthentication(HttpListenerContext listenerContext)
351
HttpStatusCode
result = base.ValidateAuthentication(listenerContext);
352
if (result ==
HttpStatusCode
.OK)
383
if (result !=
HttpStatusCode
.OK && (AuditLevel.Failure == (this.AuditBehavior.MessageAuthenticationAuditLevel & AuditLevel.Failure)))
System\ServiceModel\Channels\SharedHttpTransportManager.cs (2)
430
listenerContext.Response.StatusCode = (int)
HttpStatusCode
.MethodNotAllowed;
435
listenerContext.Response.StatusCode = (int)
HttpStatusCode
.NotFound;
System\ServiceModel\Channels\WebSocketConnectionHandler.cs (3)
37
HttpResponseMessage response = new HttpResponseMessage(
HttpStatusCode
.UpgradeRequired);
44
HttpResponseMessage response = new HttpResponseMessage(
HttpStatusCode
.BadRequest);
51
HttpResponseMessage message = new HttpResponseMessage(
HttpStatusCode
.SwitchingProtocols);
System\ServiceModel\Description\ServiceMetadataExtension.cs (11)
766
AddHttpProperty(replyMessage,
HttpStatusCode
.OK, HtmlContentType);
858
AddHttpProperty(replyMessage,
HttpStatusCode
.OK, XmlContentType);
901
AddHttpProperty(replyMessage,
HttpStatusCode
.OK, XmlContentType);
918
AddHttpProperty(replyMessage,
HttpStatusCode
.OK, XmlContentType);
945
AddHttpProperty(replyMessage,
HttpStatusCode
.OK, XmlContentType);
1012
return CreateHttpResponseMessage(
HttpStatusCode
.RequestUriTooLong);
1030
return CreateHttpResponseMessage(
HttpStatusCode
.MethodNotAllowed);
1056
AddHttpProperty(reply,
HttpStatusCode
.InternalServerError, HtmlContentType);
1288
static void AddHttpProperty(Message message,
HttpStatusCode
status, string contentType)
1298
Message redirectMessage = CreateHttpResponseMessage(
HttpStatusCode
.RedirectKeepVerb);
1304
static Message CreateHttpResponseMessage(
HttpStatusCode
code)
System\ServiceModel\Dispatcher\ClientRuntime.cs (1)
470
if (prop == null || prop.StatusCode !=
HttpStatusCode
.InternalServerError)
System.ServiceModel.Activation (10)
System\ServiceModel\Activation\HostedHttpContext.cs (6)
66
protected override
HttpStatusCode
ValidateAuthentication()
451
return HttpInput.CreateHttpProtocolException(SR.Hosting_MaxRequestLengthExceeded,
HttpStatusCode
.RequestEntityTooLarge, null, hostedException);
487
this.statusCode = (int)
HttpStatusCode
.InternalServerError;
491
this.statusCode = (int)
HttpStatusCode
.OK;
539
protected override void SetStatusCode(
HttpStatusCode
statusCode)
611
this.SetStatusCode((
HttpStatusCode
)statusCode);
System\ServiceModel\Activation\HostedHttpRequestAsyncResult.cs (4)
439
throw FxTrace.Exception.AsError(new HttpException((int)
HttpStatusCode
.NotFound, exception.Message, exception));
442
SetStatusCode((int)
HttpStatusCode
.NotFound);
462
SetStatusCode((int)
HttpStatusCode
.InternalServerError);
601
throw FxTrace.Exception.AsError(HttpInput.CreateHttpProtocolException(SR.Hosting_MaxRequestLengthExceeded,
HttpStatusCode
.RequestEntityTooLarge, null, hostedException));
System.ServiceModel.Channels (2)
System\ServiceModel\Channels\MessageExtensionMethods.cs (2)
170
message.IsFault ?
HttpStatusCode
.InternalServerError :
HttpStatusCode
.OK;
System.ServiceModel.Web (33)
System\ServiceModel\Channels\JavascriptCallbackResponseProperty.cs (1)
24
public
HttpStatusCode
? StatusCode { get; set; }
System\ServiceModel\Description\WebScriptClientGenerator.cs (1)
75
responseMessageProperty.StatusCode =
HttpStatusCode
.NotModified;
System\ServiceModel\Description\WebScriptEnablingBehavior.cs (1)
424
responseProperty.StatusCode = System.Net.
HttpStatusCode
.InternalServerError;
System\ServiceModel\Dispatcher\HelpPage.cs (1)
82
throw System.ServiceModel.DiagnosticUtility.ExceptionUtility.ThrowHelperError(new WebFaultException(
HttpStatusCode
.NotFound));
System\ServiceModel\Dispatcher\HttpUnhandledOperationInvoker.cs (3)
57
WebOperationContext.Current.OutgoingResponse.StatusCode =
HttpStatusCode
.TemporaryRedirect;
91
WebOperationContext.Current.OutgoingResponse.StatusCode = uriMatched ?
HttpStatusCode
.MethodNotAllowed :
HttpStatusCode
.NotFound;
System\ServiceModel\Dispatcher\JavascriptCallbackMessageInspector.cs (1)
72
property.StatusCode =
HttpStatusCode
.OK;
System\ServiceModel\Dispatcher\WebErrorHandler.cs (2)
127
WebOperationContext.Current.OutgoingResponse.StatusCode =
HttpStatusCode
.BadRequest;
155
responseProperty.StatusCode =
HttpStatusCode
.BadRequest;
System\ServiceModel\Dispatcher\WebFaultClientMessageInspector.cs (1)
26
if (prop != null && prop.StatusCode ==
HttpStatusCode
.InternalServerError)
System\ServiceModel\Web\IncomingWebRequestContext.cs (4)
195
throw DiagnosticUtility.ExceptionUtility.ThrowHelperError(new WebFaultException(
HttpStatusCode
.NotModified));
292
throw DiagnosticUtility.ExceptionUtility.ThrowHelperError(new WebFaultException(
HttpStatusCode
.NotModified));
319
throw DiagnosticUtility.ExceptionUtility.ThrowHelperError(new WebFaultException(
HttpStatusCode
.PreconditionFailed));
332
throw DiagnosticUtility.ExceptionUtility.ThrowHelperError(new WebFaultException(
HttpStatusCode
.PreconditionFailed));
System\ServiceModel\Web\IncomingWebResponseContext.cs (1)
39
public
HttpStatusCode
StatusCode
System\ServiceModel\Web\IWebFaultException.cs (1)
11
HttpStatusCode
StatusCode { get; }
System\ServiceModel\Web\OutgoingWebResponseContext.cs (4)
85
public
HttpStatusCode
StatusCode
216
this.StatusCode =
HttpStatusCode
.Created;
222
this.StatusCode =
HttpStatusCode
.NotFound;
227
this.StatusCode =
HttpStatusCode
.NotFound;
System\ServiceModel\Web\WebFaultException.cs (12)
25
public WebFaultException(
HttpStatusCode
statusCode)
34
this.StatusCode = (
HttpStatusCode
)info.GetValue("statusCode", typeof(
HttpStatusCode
));
37
public
HttpStatusCode
StatusCode { get; private set; }
69
internal static FaultCode GetFaultCode(
HttpStatusCode
statusCode)
71
if ((int) statusCode >= (int)
HttpStatusCode
.InternalServerError)
82
internal static string GetDefaultReason(
HttpStatusCode
statusCode)
149
public WebFaultException(T detail,
HttpStatusCode
statusCode)
155
public WebFaultException(T detail,
HttpStatusCode
statusCode, IEnumerable<Type> knownTypes)
165
this.StatusCode = (
HttpStatusCode
)info.GetValue("statusCode", typeof(
HttpStatusCode
));
169
public
HttpStatusCode
StatusCode { get; private set; }
System.Web (4)
HttpApplication.cs (1)
3650
|| context.Response.StatusCode != (int)
HttpStatusCode
.SwitchingProtocols) {
HttpContext.cs (3)
316
throw new HttpException((int)
HttpStatusCode
.BadRequest, SR.GetString(SR.WebSockets_NotAWebSocketRequest));
341
throw new HttpException((int)
HttpStatusCode
.Forbidden, SR.GetString(SR.WebSockets_OriginCheckFailed));
366
Response.StatusCode = (int)
HttpStatusCode
.SwitchingProtocols; // 101
System.Web.Extensions (2)
Handlers\ScriptModule.cs (1)
160
RestHandler.WriteExceptionJsonString(context, new InvalidOperationException(AtlasWeb.WebService_RedirectError), (int)
HttpStatusCode
.Unauthorized);
Script\Services\RestHandler.cs (1)
212
WriteExceptionJsonString(context, ex, (int)
HttpStatusCode
.InternalServerError);
System.Web.Services (17)
System\Web\Services\Discovery\DiscoveryClientProtocol.cs (1)
253
if (httpResponse.StatusCode !=
HttpStatusCode
.OK) {
System\Web\Services\Protocols\DiscoveryServerProtocol.cs (1)
342
Response.StatusCode = (int)
HttpStatusCode
.InternalServerError;
System\Web\Services\Protocols\HttpServerProtocol.cs (1)
223
SetHttpResponseStatusCode(Response, (int)
HttpStatusCode
.InternalServerError);
System\Web\Services\Protocols\ServerProtocol.cs (1)
165
Response.StatusCode = (int)
HttpStatusCode
.Accepted;
System\Web\Services\Protocols\Soap11ServerProtocol.cs (2)
88
internal override void WriteFault(XmlWriter writer, SoapException soapException,
HttpStatusCode
statusCode) {
89
if (statusCode !=
HttpStatusCode
.InternalServerError)
System\Web\Services\Protocols\Soap12ServerProtocol.cs (2)
108
internal override void WriteFault(XmlWriter writer, SoapException soapException,
HttpStatusCode
statusCode) {
109
if (statusCode !=
HttpStatusCode
.InternalServerError)
System\Web\Services\Protocols\SoapServerProtocol.cs (9)
745
HttpStatusCode
statusCode = helper.SetResponseErrorCode(Response, soapException);
826
bool WriteException_TryWriteFault(SoapServerMessage message, Stream outputStream,
HttpStatusCode
statusCode, bool disableExtensions)
932
internal
HttpStatusCode
SetResponseErrorCode(HttpResponse response, SoapException soapException) {
934
response.StatusCode = (int)
HttpStatusCode
.UnsupportedMediaType;
939
(int)
HttpStatusCode
.InternalServerError);
943
response.StatusCode = (int)
HttpStatusCode
.BadRequest;
949
(int)
HttpStatusCode
.InternalServerError);
952
return (
HttpStatusCode
)response.StatusCode;
955
internal abstract void WriteFault(XmlWriter writer, SoapException soapException,
HttpStatusCode
statusCode);
System.Xaml.Hosting (1)
System\Xaml\Hosting\XamlHttpHandlerFactory.cs (1)
91
throw FxTrace.Exception.AsError(new HttpException((int)
HttpStatusCode
.NotFound, SR.ResourceNotFound));