Package aQute.bnd.http
Class ProgressWrappingStream
java.lang.Object
java.io.InputStream
aQute.bnd.http.ProgressWrappingStream
- All Implemented Interfaces:
Closeable,AutoCloseable
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final AtomicBooleanprivate InputStreamprivate intprivate intprivate intprivate longprivate ProgressPlugin.Taskprivate final long -
Constructor Summary
ConstructorsConstructorDescriptionProgressWrappingStream(InputStream delegate, String name, int size, ProgressPlugin.Task task, long timeout) -
Method Summary
Methods inherited from class java.io.InputStream
available, mark, markSupported, nullInputStream, readAllBytes, readNBytes, readNBytes, reset, skip, skipNBytes, transferTo
-
Field Details
-
delegate
-
task
-
size
private int size -
reported
private int reported -
read
private int read -
timeout
private final long timeout -
closed
-
startNanos
private long startNanos
-
-
Constructor Details
-
ProgressWrappingStream
public ProgressWrappingStream(InputStream delegate, String name, int size, ProgressPlugin.Task task, long timeout)
-
-
Method Details
-
read
- Specified by:
readin classInputStream- Throws:
IOException
-
isTimeout
- Throws:
IOException
-
read
- Overrides:
readin classInputStream- Throws:
IOException
-
read
- Overrides:
readin classInputStream- Throws:
IOException
-
update
- Throws:
IOException
-
close
- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable- Overrides:
closein classInputStream- Throws:
IOException
-