code: public static boolean flush(final OutputStream[] streams) {
        boolean success = true;
  
        for (OutputStream stream : streams) {
           boolean rv = flush(stream);
           if (!rv) success = false;
        }
  
        return success;
     }
docs: Attempt to flush an array of <tt>OutputStream</tt>s.
  
  @param streams <tt>OutputStream</tt>s to attempt to flush.
  @return <tt>True</tt> if all streams were flushed, or <tt>false</tt> if
  an exception was thrown.