code: public static Writer createWriter(FileSystem fs,
                                      Path path,
                                      Configuration conf,
                                      ObjectInspector inspector,
                                      long stripeSize,
                                      CompressionKind compress,
                                      int bufferSize,
                                      int rowIndexStride) throws IOException {
      return new WriterImpl(fs, path, conf, inspector, stripeSize, compress,
        bufferSize, rowIndexStride, getMemoryManager(conf));
    }
docs: Create an ORC file streamFactory.
  @param fs file system
  @param path filename to write to
  @param inspector the ObjectInspector that inspects the rows
  @param stripeSize the number of bytes in a stripe
  @param compress how to compress the file
  @param bufferSize the number of bytes to compress at once
  @param rowIndexStride the number of rows between row index entries or
  0 to suppress all indexes
  @return a new ORC file streamFactory
  @throws IOException