private static IDictionary <string, string> ReadRequestProperties(HttpConfiguration config, string url, HttpMethod httpMethod, string body) { var request = new HttpRequestMessage(httpMethod, url); request.Content = new StringContent(body); var routeGenerator = new Generator(config, request); return(routeGenerator.ReadRequestProperties(url, httpMethod)); }
private static RouteValues ReadRequestProperties(HttpConfiguration config, string url, HttpMethod httpMethod, Dictionary <string, string> headers, string body, BodyFormat bodyFormat) { var request = new HttpRequestMessage(httpMethod, url); if (headers != null) { foreach (var header in headers) { request.Headers.Add(header.Key, header.Value); } } request.Content = new StringContent(body); var routeGenerator = new Generator(config, request); return(routeGenerator.ReadRequestProperties(url, httpMethod, bodyFormat)); }
private static IDictionary<string, string> ReadRequestProperties(HttpConfiguration config, string url, HttpMethod httpMethod, string body) { var request = new HttpRequestMessage(httpMethod, url); request.Content = new StringContent(body); var routeGenerator = new Generator(config, request); return routeGenerator.ReadRequestProperties(url, httpMethod); }