code: public static ByteArrayOutputStream input2OutputStream(final InputStream is) {
          if (is == null) return null;
          try {
              ByteArrayOutputStream os = new ByteArrayOutputStream();
              byte[]                b  = new byte[MemoryConst.KB];
              int                   len;
              while ((len = is.read(b, 0, MemoryConst.KB)) != -1) {
                  os.write(b, 0, len);
              }
              return os;
          } catch (IOException e) {
              e.printStackTrace();
              return null;
          } finally {
              IOKit.closeQuietly(is);
          }
      }
docs: inputStream转outputStream
  
  @param is 输入流
  @return outputStream子类