Package org.primefaces.util
Class IOUtils
java.lang.Object
org.primefaces.util.IOUtils
-
Method Summary
Modifier and TypeMethodDescriptionstatic voidcloseQuietly(AutoCloseable closeable, Consumer<Exception> consumer) Closes the givenCloseableas a null-safe operation while consuming IOException by the givenconsumer.static voidcopyLarge(InputStream input, OutputStream output) static byte[]toByteArray(InputStream input) static StringtoString(InputStream is, Charset charset)
-
Method Details
-
toString
- Throws:
IOException
-
toByteArray
- Throws:
IOException
-
copyLarge
- Throws:
IOException
-
closeQuietly
Closes the givenCloseableas a null-safe operation while consuming IOException by the givenconsumer.- Parameters:
closeable- The resource to close, may be null.consumer- Consumes the IOException thrown byCloseable.close().
-