Uses of Class
org.miaixz.bus.http.bodys.RequestBody
Packages that use RequestBody
Package
Description
An HTTP client for Java applications.
Provides classes for handling HTTP request and response bodies.
Provides the core implementation classes for the Httpv client, including task management, execution, data conversion,
and WebSocket support.
Provides a fluent, builder-based API (Httpz) for making HTTP requests, simplifying interactions with the core
Httpd client.-
Uses of RequestBody in org.miaixz.bus.http
Methods in org.miaixz.bus.http that return RequestBodyMethods in org.miaixz.bus.http with parameters of type RequestBodyModifier and TypeMethodDescriptionRequest.Builder.delete(RequestBody body) Sets this request to be a DELETE request with a request body.Request.Builder.method(String method, RequestBody body) Sets the HTTP method and request body.Request.Builder.patch(RequestBody body) Sets this request to be a PATCH request.Request.Builder.post(RequestBody body) Sets this request to be a POST request.Request.Builder.put(RequestBody body) Sets this request to be a PUT request. -
Uses of RequestBody in org.miaixz.bus.http.bodys
Subclasses of RequestBody in org.miaixz.bus.http.bodysModifier and TypeClassDescriptionfinal classAn HTTP request body that represents form-encoded data.classA MIME multipart request body.Methods in org.miaixz.bus.http.bodys that return RequestBodyModifier and TypeMethodDescriptionMultipartBody.Part.body()Returns the body of this part.static RequestBodyRequestBody.create(org.miaixz.bus.core.lang.MediaType contentType, byte[] content) Creates a new request body from a byte array.static RequestBodyRequestBody.create(org.miaixz.bus.core.lang.MediaType contentType, byte[] content, int offset, int byteCount) Creates a new request body from a portion of a byte array.static RequestBodyCreates a new request body from a file.static RequestBodyCreates a new request body from a string.static RequestBodyRequestBody.create(org.miaixz.bus.core.lang.MediaType contentType, org.miaixz.bus.core.io.ByteString content) Creates a new request body from aByteString.Methods in org.miaixz.bus.http.bodys with parameters of type RequestBodyModifier and TypeMethodDescriptionMultipartBody.Builder.addFormDataPart(String name, String filename, RequestBody body) Adds a form-data part with a filename.MultipartBody.Builder.addPart(RequestBody body) Adds a part with no headers.MultipartBody.Builder.addPart(Headers headers, RequestBody body) Adds a part with the given headers and body.static MultipartBody.PartMultipartBody.Part.create(RequestBody body) Creates a new part with no headers.static MultipartBody.PartMultipartBody.Part.create(Headers headers, RequestBody body) Creates a new part with the given headers and body.static MultipartBody.PartMultipartBody.Part.createFormData(String name, String filename, RequestBody body) Creates a new form-data part with a filename. -
Uses of RequestBody in org.miaixz.bus.http.plugin.httpv
Subclasses of RequestBody in org.miaixz.bus.http.plugin.httpvModifier and TypeClassDescriptionclassARequestBodydecorator that monitors the progress of an upload.Constructors in org.miaixz.bus.http.plugin.httpv with parameters of type RequestBodyModifierConstructorDescriptionProgressBody(RequestBody requestBody, Callback<Progress> onProcess, Executor callbackExecutor, long contentLength, long stepBytes) Constructs a new ProgressBody. -
Uses of RequestBody in org.miaixz.bus.http.plugin.httpz
Methods in org.miaixz.bus.http.plugin.httpz that return RequestBodyModifier and TypeMethodDescriptionprotected RequestBodyDeleteRequest.buildRequestBody()Builds the request body.protected RequestBodyGetRequest.buildRequestBody()Builds the request body.protected RequestBodyHeadRequest.buildRequestBody()Builds the request body.protected abstract RequestBodyHttpRequest.buildRequestBody()Abstract method to be implemented by subclasses to construct the specific request body (e.g., for POST, PUT).protected RequestBodyPostRequest.buildRequestBody()Builds the request body based on the provided parameters.protected RequestBodyPutRequest.buildRequestBody()Builds the request body based on the provided parameters.static RequestBodyHttpRequest.createRequestBody(org.miaixz.bus.core.lang.MediaType contentType, InputStream is) A static factory method to create aRequestBodyfrom anInputStream.Methods in org.miaixz.bus.http.plugin.httpz with parameters of type RequestBodyModifier and TypeMethodDescriptionprotected RequestDeleteRequest.buildRequest(RequestBody requestBody) Builds the final HttpdRequestobject.protected RequestGetRequest.buildRequest(RequestBody requestBody) Builds the final HttpdRequestobject.protected RequestHeadRequest.buildRequest(RequestBody requestBody) Builds the final HttpdRequestobject.protected abstract RequestHttpRequest.buildRequest(RequestBody requestBody) Abstract method to be implemented by subclasses to construct the finalRequestobject with the correct HTTP method.protected RequestPostRequest.buildRequest(RequestBody requestBody) protected RequestPutRequest.buildRequest(RequestBody requestBody)