tags:

views:

68

answers:

2

I'am a big fan of http://php.net/manual/en/function.flush.php

Can I do the same thing using Java?

thanks for your help

+1  A: 

OutputStream.flush()

nanda
+2  A: 

Since the equivalent of PHP in java is jsp+servlets, here are the ways to do it:

  • in a servlet, call response.getOutputStream().flush()
  • in a jsp it's the same, but you have to specify <%@ page autoFlush="false" %>
Bozho