Send feedback
Class Apache5ResponseContent (1.45.0)
Stay organized with collections
Save and categorize content based on your preferences.
Version latest keyboard_arrow_down
public class Apache5ResponseContent extends InputStream
Class that wraps an org.apache.hc.core5.http.HttpEntity 's content InputStream
along with the ClassicHttpResponse that contains this entity. The main purpose is to be
able to close the response as well as the content input stream when #close() is called,
in order to not break the existing contract with clients using apache v4 that only required them
to close the input stream to clean up all resources.
Constructors
Apache5ResponseContent(InputStream wrappedStream, ClassicHttpResponse response)
public Apache5ResponseContent ( InputStream wrappedStream , ClassicHttpResponse response )
Parameters
Name
Description
wrappedStream
InputStream
response
org.apache.hc.core5.http.ClassicHttpResponse
Methods
available()
Returns
Type
Description
int
Overrides
close()
Overrides
mark(int readlimit)
public synchronized void mark ( int readlimit )
Parameter
Name
Description
readlimit
int
Overrides
markSupported()
public boolean markSupported ()
Overrides
read()
Returns
Type
Description
int
Overrides
read(byte[] b)
public int read ( byte [] b )
Parameter
Name
Description
b
byte []
Returns
Type
Description
int
Overrides
read(byte[] b, int off, int len)
public int read ( byte [] b , int off , int len )
Parameters
Name
Description
b
byte []
off
int
len
int
Returns
Type
Description
int
Overrides
reset()
public synchronized void reset ()
Overrides
skip(long n)
Parameter
Name
Description
n
long
Returns
Type
Description
long
Overrides
Send feedback
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License , and code samples are licensed under the Apache 2.0 License . For details, see the Google Developers Site Policies . Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2024-09-19 UTC.
[{
"type": "thumb-down",
"id": "hardToUnderstand",
"label":"Hard to understand"
},{
"type": "thumb-down",
"id": "incorrectInformationOrSampleCode",
"label":"Incorrect information or sample code"
},{
"type": "thumb-down",
"id": "missingTheInformationSamplesINeed",
"label":"Missing the information/samples I need"
},{
"type": "thumb-down",
"id": "otherDown",
"label":"Other"
}]
[{
"type": "thumb-up",
"id": "easyToUnderstand",
"label":"Easy to understand"
},{
"type": "thumb-up",
"id": "solvedMyProblem",
"label":"Solved my problem"
},{
"type": "thumb-up",
"id": "otherUp",
"label":"Other"
}]
Need to tell us more?
{"lastModified": "Last updated 2024-09-19 UTC."}