I want a inputTextarea to display lines appended to some text file. I imagine it like this: The user clicks a commandButton that does a AJAX call.
My problem is: The text will only be rendered when the action returns. However, my action should look like this:
while(true) {
String newData = getSomeMoreDataFromServer();
// append the new data to a textarea and the user should see it immediately
if(blabla) { break; }
}
Is this even possible? The part that's commented out is the part that bothers me.
Can the user even set the break condition in the form somehow?
I'm using JSF 2 (MyFaces) + Tomahawk.