MCPcopy Create free account
hub / github.com/apache/orc / createWriter

Method createWriter

java/core/src/java/org/apache/orc/OrcFile.java:1096–1111  ·  view source on GitHub ↗

Create an ORC file writer. This is the public interface for creating writers going forward and new options will only be added to this method. @param path filename to write to @param opts the options @return a new ORC file writer @throws IOException

(Path path,
                                    WriterOptions opts
                                    )

Source from the content-addressed store, hash-verified

1094 * @throws IOException
1095 */
1096 public static Writer createWriter(Path path,
1097 WriterOptions opts
1098 ) throws IOException {
1099 FileSystem fs = opts.getFileSystem() == null ?
1100 path.getFileSystem(opts.getConfiguration()) : opts.getFileSystem();
1101 switch (opts.getVersion()) {
1102 case V_0_11:
1103 case V_0_12:
1104 return new WriterImpl(fs, path, opts);
1105 case UNSTABLE_PRE_2_0:
1106 return new WriterImplV2(fs, path, opts);
1107 default:
1108 throw new IllegalArgumentException("Unknown version " +
1109 opts.getVersion());
1110 }
1111 }
1112
1113 /**
1114 * Do we understand the version in the reader?

Callers 15

testCountMethod · 0.95
testJsonDumpMethod · 0.95
testMergeMethod · 0.95
testScanMethod · 0.95
testDumpMethod · 0.95
testDataDumpMethod · 0.95
testBloomFilterMethod · 0.95
testBloomFilter2Method · 0.95
testHasNullMethod · 0.95
testRecoverMethod · 0.95

Calls 3

getConfigurationMethod · 0.65
getVersionMethod · 0.65
getFileSystemMethod · 0.45

Tested by 15

testCountMethod · 0.76
testJsonDumpMethod · 0.76
testMergeMethod · 0.76
testScanMethod · 0.76
testDumpMethod · 0.76
testDataDumpMethod · 0.76
testBloomFilterMethod · 0.76
testBloomFilter2Method · 0.76
testHasNullMethod · 0.76
testRecoverMethod · 0.76