Class SizeLimitedInputStream
java.lang.Object
java.io.InputStream
com.atlassian.confluence.util.http.SizeLimitedInputStream
- All Implemented Interfaces:
Closeable,AutoCloseable
Deprecated, for removal: This API element is subject to removal in a future version.
since 7.0.1 will be removed in 9.0
This is a wrapper around an InputStream that limits the amount of data that can be returned. This allows admins
to set maximum download sizes for Confluence retrieved content, so that people can't, say, point the RSS macro
at an ISO file and cause the system to collapse painfully.
If you try to retrieve more than the maximum allowed size, the read() methods will fail with an IOException
-
Constructor Summary
ConstructorsConstructorDescriptionSizeLimitedInputStream(InputStream wrappedInputStream, int maxBytesToRead) Deprecated, for removal: This API element is subject to removal in a future version. -
Method Summary
Modifier and TypeMethodDescriptionintDeprecated, for removal: This API element is subject to removal in a future version.voidclose()Deprecated, for removal: This API element is subject to removal in a future version.voidmark(int readlimit) Deprecated, for removal: This API element is subject to removal in a future version.booleanDeprecated, for removal: This API element is subject to removal in a future version.intread()Deprecated, for removal: This API element is subject to removal in a future version.voidreset()Deprecated, for removal: This API element is subject to removal in a future version.longskip(long n) Deprecated, for removal: This API element is subject to removal in a future version.Methods inherited from class java.io.InputStream
nullInputStream, read, read, readAllBytes, readNBytes, readNBytes, skipNBytes, transferTo
-
Constructor Details
-
SizeLimitedInputStream
Deprecated, for removal: This API element is subject to removal in a future version.
-
-
Method Details
-
read
Deprecated, for removal: This API element is subject to removal in a future version.- Specified by:
readin classInputStream- Throws:
IOException
-
skip
Deprecated, for removal: This API element is subject to removal in a future version.- Overrides:
skipin classInputStream- Throws:
IOException
-
close
Deprecated, for removal: This API element is subject to removal in a future version.- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable- Overrides:
closein classInputStream- Throws:
IOException
-
available
Deprecated, for removal: This API element is subject to removal in a future version.- Overrides:
availablein classInputStream- Throws:
IOException
-
mark
public void mark(int readlimit) Deprecated, for removal: This API element is subject to removal in a future version.- Overrides:
markin classInputStream
-
reset
Deprecated, for removal: This API element is subject to removal in a future version.- Overrides:
resetin classInputStream- Throws:
IOException
-
markSupported
public boolean markSupported()Deprecated, for removal: This API element is subject to removal in a future version.- Overrides:
markSupportedin classInputStream
-