PlayFramework - what is the alternative to response.getBodyAsStream()?

183 views Asked by At

The language says that "response.getBodyAsStream()" is deprecated. Neat, what method do i use?

* @deprecated use {@link #getBody(BodyReadable)} with {@code WSBodyWritables.inputStream()}.

Oh...

That's not... english? Or anything, really. So. Do any of you clever stackoverflowers know how the hell I am meant to do the getBodyAsStream?

1

There are 1 answers

0
CornelZ On

From the source code this should work in java.

response.getBody(WSBodyReadables.instance.inputStream());