Package com.inrupt.client.util
Class IOUtils
java.lang.Object
com.inrupt.client.util.IOUtils
IOUtility methods for use with the Inrupt Java Client Libraries.
-
Method Summary
Modifier and TypeMethodDescriptionstatic Request.BodyPublisher
buffer
(Consumer<OutputStream> function) Buffer a request body from a consuming function.static InputStream
pipe
(Consumer<OutputStream> function) Pipe an output stream to a consumable input stream.static Request.BodyPublisher
stream
(Consumer<OutputStream> function) Stream a request body directly from a consuming function.
-
Method Details
-
pipe
Pipe an output stream to a consumable input stream.- Parameters:
function
- the output stream- Returns:
- a consumable input stream
-
stream
Stream a request body directly from a consuming function.- Parameters:
function
- the consuming function- Returns:
- the request publisher
-
buffer
Buffer a request body from a consuming function.- Parameters:
function
- the consuming function- Returns:
- the request publisher
-