Class ZeroCopyPut
java.lang.Object
org.apache.http.nio.client.methods.BaseZeroCopyRequestProducer
org.apache.http.nio.client.methods.ZeroCopyPut
- All Implemented Interfaces:
Closeable
,AutoCloseable
,org.apache.http.nio.protocol.HttpAsyncRequestProducer
HttpAsyncRequestProducer
implementation
that generates an HTTP PUT
request enclosing content of a file.
The request content will be streamed out directly from the underlying file
without an intermediate in-memory buffer.- Since:
- 4.0
-
Constructor Summary
ConstructorsConstructorDescriptionZeroCopyPut
(String requestURI, File content, org.apache.http.entity.ContentType contentType) ZeroCopyPut
(URI requestURI, File content, org.apache.http.entity.ContentType contentType) -
Method Summary
Modifier and TypeMethodDescriptionprotected org.apache.http.HttpEntityEnclosingRequest
createRequest
(URI requestURI, org.apache.http.HttpEntity entity) Methods inherited from class org.apache.http.nio.client.methods.BaseZeroCopyRequestProducer
close, failed, generateRequest, getTarget, isRepeatable, produceContent, requestCompleted, resetRequest
-
Constructor Details
-
ZeroCopyPut
public ZeroCopyPut(URI requestURI, File content, org.apache.http.entity.ContentType contentType) throws FileNotFoundException - Throws:
FileNotFoundException
-
ZeroCopyPut
public ZeroCopyPut(String requestURI, File content, org.apache.http.entity.ContentType contentType) throws FileNotFoundException - Throws:
FileNotFoundException
-
-
Method Details
-
createRequest
protected org.apache.http.HttpEntityEnclosingRequest createRequest(URI requestURI, org.apache.http.HttpEntity entity) - Specified by:
createRequest
in classBaseZeroCopyRequestProducer
-