/** * Creates a new {@link OperationRequest}. The given {@code headers} will be augmented * to ensure that they always include a {@code Content-Length} header if the request * has any content and a {@code Host} header. * @param uri the request's uri * @param method the request method * @param content the content of the request * @param headers the request's headers * @param parameters the request's parameters * @param parts the request's parts * @param cookies the request's cookies * @return the {@code OperationRequest} */ public OperationRequest create(URI uri, HttpMethod method, byte[] content, HttpHeaders headers, Parameters parameters, Collection<OperationRequestPart> parts, Collection<RequestCookie> cookies) { return new StandardOperationRequest(uri, method, content, augmentHeaders(headers, uri, content), parameters, parts, cookies); }