private static void shovelInToOut(InputStream in,OutputStream out) throws IOException {
synchronized (tmpbuffer) {
    int len;
    while ((len=in.read(tmpbuffer)) > 0) {
      out.write(tmpbuffer,0,len);
    }
  }
}

private static void shovelInToOut ( InputStream in , OutputStream out ) throws IOException { synchronized ( tmpbuffer ) { int len ; while ( ( len = in . read ( tmpbuffer ) ) > 0 ) { out . write ( tmpbuffer , 0 , len ) ; } } }
shovels all data from an input stream to an output stream .
