code: public static void copy(final InputStream inputStream, final OutputStream outputStream)
        throws IOException {
      new ByteSource() {
        @Override
        public InputStream openStream() {
          return inputStream;
        }
      }.copyTo(new ByteSink() {
        @Override
        public OutputStream openStream() {
          return outputStream;
        }
      });
    }
docs: Copies the {@code inputStream} into the {@code outputSteam} and finally
  closes the both streams.