public void printBody ( final OutputStream output ) throws IOException { //@checkstyle MagicNumberCheck (1 line) final byte [ ] buf = new byte [ 4096 ] ; try ( InputStream body = this . body ( ) ) { while ( true ) { final int bytes = body . read ( buf ) ; if ( bytes < 0 ) { break ; } output . write ( buf , 0 , bytes ) ; } } finally { output . flush ( ) ; } }
Print it into output stream .