public static class AutoCloseInputStream.Builder extends AbstractStreamBuilder<T,B>
AutoCloseInputStream instance.
For example:
AutoCloseInputStream s = AutoCloseInputStream.builder()
.setPath(path)
.get();
AutoCloseInputStream s = AutoCloseInputStream.builder()
.setInputStream(inputStream)
.get();
get()| Constructor and Description |
|---|
Builder()
Constructs a new builder of
AutoCloseInputStream. |
| Modifier and Type | Method and Description |
|---|---|
AutoCloseInputStream |
get()
Builds a new
AutoCloseInputStream. |
getBufferSize, getBufferSizeDefault, getCharSequence, getCharset, getCharsetDefault, getFile, getInputStream, getOpenOptions, getOutputStream, getPath, getRandomAccessFile, getReader, getWriter, setBufferSize, setBufferSize, setBufferSizeChecker, setBufferSizeMax, setCharset, setCharset, setOpenOptionssetByteArray, setCharSequence, setFile, setFile, setInputStream, setOutputStream, setPath, setPath, setRandomAccessFile, setRandomAccessFile, setReader, setURI, setWriterequals, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitasSupplier, getUncheckedpublic Builder()
AutoCloseInputStream.public AutoCloseInputStream get() throws java.io.IOException
AutoCloseInputStream.
You must set an aspect that supports AbstractStreamBuilder.getInputStream(), otherwise, this method throws an exception.
This builder uses the following aspects:
AbstractStreamBuilder.getInputStream() gets the target aspect.java.lang.IllegalStateException - if the origin is null.java.lang.UnsupportedOperationException - if the origin cannot be converted to an InputStream.java.io.IOException - if an I/O error occurs converting to an InputStream using AbstractStreamBuilder.getInputStream().AbstractStreamBuilder.getInputStream(),
IOSupplier.getUnchecked()Copyright © 2010 - 2025 Adobe. All Rights Reserved