/// <summary>Enables processing of HTTP Web requests by a custom HttpHandler that implements the <see cref="T:System.Web.IHttpHandler" /> interface.</summary> /// /// <param name="context">An <see cref="T:System.Web.HttpContext" /> object that provides references to the intrinsic server objects (for example, Request, Response, Session, and Server) used to /// service HTTP requests. /// </param> public new void ProcessRequest(HttpContext context) { if (context.Request.HttpMethod == HttpMethods.Get) { var wsdl = new Soap12WsdlMetadataHandler(); wsdl.Execute(context); return; } SendOneWay(null); }
/// <summary>Enables processing of HTTP Web requests by a custom HttpHandler that implements the <see cref="T:System.Web.IHttpHandler" /> interface.</summary> /// /// <param name="context">An <see cref="T:System.Web.HttpContext" /> object that provides references to the intrinsic server objects (for example, Request, Response, Session, and Server) used to /// service HTTP requests. /// </param> public new void ProcessRequest(HttpContext context) { if (context.Request.HttpMethod == HttpMethods.Get) { var wsdl = new Soap12WsdlMetadataHandler(); wsdl.Execute(context); return; } var responseMessage = Send(null); context.Response.ContentType = GetSoapContentType(context.Request.ContentType); using (var writer = XmlWriter.Create(context.Response.OutputStream)) { responseMessage.WriteMessage(writer); } }
/// <summary>Process the request.</summary> /// /// <param name="httpReq"> The HTTP request.</param> /// <param name="httpRes"> The HTTP resource.</param> /// <param name="operationName">Name of the operation.</param> public override void ProcessRequest(IHttpRequest httpReq, IHttpResponse httpRes, string operationName) { if (httpReq.HttpMethod == HttpMethods.Get) { var wsdl = new Soap12WsdlMetadataHandler(); wsdl.Execute(httpReq, httpRes); return; } var responseMessage = Send(null, httpReq, httpRes); httpRes.ContentType = GetSoapContentType(httpReq.ContentType); using (var writer = XmlWriter.Create(httpRes.OutputStream)) { responseMessage.WriteMessage(writer); } }