I am challenged by something pretty simple. I create an HTTP POST request and I want to read the response body into a variable. The response body is always a single string of around 300 chars.
In plain Java, this is trivial. However, I can find no examples of doing it in JavaFX using HttpRequest. All the examples do useless things like print the number of bytes returned.
First, how the heck do you create a sized byte array in JavaFX? You can't do it with nativearray, it seems. So, the seemingly obvious method of creating a byte array, reading the InputStream into it, converting it to a string; is right out.
I have tried everything I can think of. Appreciate any help.