public HostedRequestHttpOutput(HostedHttpRequestAsyncResult result, IHttpTransportFactorySettings settings, Message message, HostedHttpContext context) : base(settings, message, false, false) { this.result = result; this.context = context; if (TransferModeHelper.IsResponseStreamed(settings.TransferMode)) { result.SetTransferModeToStreaming(); } if (message.IsFault) { this.statusCode = 500; } else { this.statusCode = 200; } }
public HostedRequestHttpOutput(HostedHttpRequestAsyncResult result, IHttpTransportFactorySettings settings, Message message, HostedHttpContext context) : base(settings, message, false, false) { AspNetPartialTrustHelpers.FailIfInPartialTrustOutsideAspNet(); this.result = result; this.context = context; if (TransferModeHelper.IsResponseStreamed(settings.TransferMode)) { result.SetTransferModeToStreaming(); } if (message.IsFault) { this.statusCode = (int)HttpStatusCode.InternalServerError; } else { this.statusCode = (int)HttpStatusCode.OK; } }
public HostedRequestHttpOutput(HostedHttpRequestAsyncResult result, IHttpTransportFactorySettings settings, Message message, HostedHttpContext context) : base(settings, message, false, false) { AspNetPartialTrustHelpers.FailIfInPartialTrustOutsideAspNet(); this.result = result; this.context = context; if (TransferModeHelper.IsResponseStreamed(settings.TransferMode)) result.SetTransferModeToStreaming(); if (message.IsFault) { this.statusCode = (int)HttpStatusCode.InternalServerError; } else { this.statusCode = (int)HttpStatusCode.OK; } }