Package com.liferay.portal.kernel.util
Class StreamUtil
Object
com.liferay.portal.kernel.util.StreamUtil
- Author:
- Brian Wing Shun Chan, Raymond Augé, Shuyang Zhou
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic voidstatic voidtransfer(InputStream inputStream, OutputStream outputStream) static voidtransfer(InputStream inputStream, OutputStream outputStream, boolean cleanUp) static voidtransfer(InputStream inputStream, OutputStream outputStream, int bufferSize) static voidtransfer(InputStream inputStream, OutputStream outputStream, int bufferSize, boolean cleanUp) static voidtransfer(InputStream inputStream, OutputStream outputStream, int bufferSize, boolean cleanUp, long length) static voidtransfer(InputStream inputStream, OutputStream outputStream, long length) protected static voidtransferByteArray(InputStream inputStream, OutputStream outputStream, int bufferSize, long length) protected static voidtransferFileChannel(FileChannel inputFileChannel, FileChannel outputFileChannel, long length) static InputStreamuncloseable(InputStream inputStream) static OutputStreamuncloseable(OutputStream outputStream)
-
Field Details
-
BUFFER_SIZE
public static final int BUFFER_SIZE -
FORCE_TIO
public static final boolean FORCE_TIO
-
-
Constructor Details
-
StreamUtil
public StreamUtil()
-
-
Method Details
-
cleanUp
-
transfer
- Throws:
IOException
-
transfer
public static void transfer(InputStream inputStream, OutputStream outputStream, boolean cleanUp) throws IOException - Throws:
IOException
-
transfer
public static void transfer(InputStream inputStream, OutputStream outputStream, int bufferSize) throws IOException - Throws:
IOException
-
transfer
public static void transfer(InputStream inputStream, OutputStream outputStream, int bufferSize, boolean cleanUp) throws IOException - Throws:
IOException
-
transfer
public static void transfer(InputStream inputStream, OutputStream outputStream, int bufferSize, boolean cleanUp, long length) throws IOException - Throws:
IOException
-
transfer
public static void transfer(InputStream inputStream, OutputStream outputStream, long length) throws IOException - Throws:
IOException
-
uncloseable
-
uncloseable
-
transferByteArray
protected static void transferByteArray(InputStream inputStream, OutputStream outputStream, int bufferSize, long length) throws IOException - Throws:
IOException
-
transferFileChannel
protected static void transferFileChannel(FileChannel inputFileChannel, FileChannel outputFileChannel, long length) throws IOException - Throws:
IOException
-