@InterfaceAudience.Private public class DelegatingInputStream extends FilterInputStream
For example, a ByteArrayInputStream, which is implicitly bounded by the size of the underlying byte array can be converted into an unbounded stream fed by multiple instances of ByteArrayInputStream, switched out one for the other in sequence.
Although multithreaded access is allowed, users of this class will want to take care to order operations on this stream and the swap out of one delegate for another in a way that provides a valid view of stream contents.
in
Constructor and Description |
---|
DelegatingInputStream(InputStream in) |
Modifier and Type | Method and Description |
---|---|
InputStream |
getDelegate() |
void |
setDelegate(InputStream in) |
available, close, mark, markSupported, read, read, read, reset, skip
public DelegatingInputStream(InputStream in)
public InputStream getDelegate()
public void setDelegate(InputStream in)
Copyright © 2007–2020 The Apache Software Foundation. All rights reserved.