gpt4 book ai didi

com.github.luben.zstd.ZstdOutputStream.()方法的使用及代码示例

转载 作者:知者 更新时间:2024-03-16 06:03:31 25 4
gpt4 key购买 nike

本文整理了Java中com.github.luben.zstd.ZstdOutputStream.<init>()方法的一些代码示例,展示了ZstdOutputStream.<init>()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。ZstdOutputStream.<init>()方法的具体详情如下:
包路径:com.github.luben.zstd.ZstdOutputStream
类名称:ZstdOutputStream
方法名:<init>

ZstdOutputStream.<init>介绍

暂无

代码示例

代码示例来源:origin: org.apache.commons/commons-compress

/**
 * Wraps the given stream into a zstd-jni ZstdOutputStream using the default values for {@code level}, {@code
 * closeFrameOnFlush} and {@code useChecksum}.
 * @param outStream the stream to write to
 * @throws IOException if zstd-jni does
 */
public ZstdCompressorOutputStream(final OutputStream outStream) throws IOException {
  this.encOS = new ZstdOutputStream(outStream);
}

代码示例来源:origin: org.apache.commons/commons-compress

/**
 * Wraps the given stream into a zstd-jni ZstdOutputStream using the default value for {@code useChecksum}.
 * @param outStream the stream to write to
 * @param level value for zstd-jni's level argument
 * @param closeFrameOnFlush value for zstd-jni's closeFrameOnFlush argument
 * @throws IOException if zstd-jni does
 * @since 1.18
 */
public ZstdCompressorOutputStream(final OutputStream outStream, int level, boolean closeFrameOnFlush)
  throws IOException {
  this.encOS = new ZstdOutputStream(outStream, level, closeFrameOnFlush);
}

代码示例来源:origin: org.apache.commons/commons-compress

/**
 * Wraps the given stream into a zstd-jni ZstdOutputStream using the default values for {@code closeFrameOnFlush}
 * and {@code useChecksum}.
 * @param outStream the stream to write to
 * @param level value for zstd-jni's level argument
 * @throws IOException if zstd-jni does
 * @since 1.18
 */
public ZstdCompressorOutputStream(final OutputStream outStream, int level) throws IOException {
  this.encOS = new ZstdOutputStream(outStream, level);
}

代码示例来源:origin: org.apache.commons/commons-compress

/**
 * Wraps the given stream into a zstd-jni ZstdOutputStream.
 * @param outStream the stream to write to
 * @param level value for zstd-jni's level argument
 * @param closeFrameOnFlush value for zstd-jni's closeFrameOnFlush argument
 * @param useChecksum value for zstd-jni's useChecksum argument
 * @throws IOException if zstd-jni does
 * @since 1.18
 */
public ZstdCompressorOutputStream(final OutputStream outStream, int level, boolean closeFrameOnFlush,
  boolean useChecksum) throws IOException {
  this.encOS = new ZstdOutputStream(outStream, level, closeFrameOnFlush, useChecksum);
}

代码示例来源:origin: KostyaSha/yet-another-docker-plugin

/**
 * Wraps the given stream into a zstd-jni ZstdOutputStream using the default values for {@code level}, {@code
 * closeFrameOnFlush} and {@code useChecksum}.
 * @param outStream the stream to write to
 * @throws IOException if zstd-jni does
 */
public ZstdCompressorOutputStream(final OutputStream outStream) throws IOException {
  this.encOS = new ZstdOutputStream(outStream);
}

代码示例来源:origin: com.impetus.fabric/fabric-jdbc-driver-shaded

public ZstdCompressorOutputStream(final OutputStream out) throws IOException {
  this.encOS = new ZstdOutputStream(out);
}

代码示例来源:origin: KostyaSha/yet-another-docker-plugin

/**
 * Wraps the given stream into a zstd-jni ZstdOutputStream using the default value for {@code useChecksum}.
 * @param outStream the stream to write to
 * @param level value for zstd-jni's level argument
 * @param closeFrameOnFlush value for zstd-jni's closeFrameOnFlush argument
 * @throws IOException if zstd-jni does
 * @since 1.18
 */
public ZstdCompressorOutputStream(final OutputStream outStream, int level, boolean closeFrameOnFlush)
  throws IOException {
  this.encOS = new ZstdOutputStream(outStream, level, closeFrameOnFlush);
}

代码示例来源:origin: KostyaSha/yet-another-docker-plugin

/**
 * Wraps the given stream into a zstd-jni ZstdOutputStream using the default values for {@code closeFrameOnFlush}
 * and {@code useChecksum}.
 * @param outStream the stream to write to
 * @param level value for zstd-jni's level argument
 * @throws IOException if zstd-jni does
 * @since 1.18
 */
public ZstdCompressorOutputStream(final OutputStream outStream, int level) throws IOException {
  this.encOS = new ZstdOutputStream(outStream, level);
}

代码示例来源:origin: KostyaSha/yet-another-docker-plugin

/**
 * Wraps the given stream into a zstd-jni ZstdOutputStream.
 * @param outStream the stream to write to
 * @param level value for zstd-jni's level argument
 * @param closeFrameOnFlush value for zstd-jni's closeFrameOnFlush argument
 * @param useChecksum value for zstd-jni's useChecksum argument
 * @throws IOException if zstd-jni does
 * @since 1.18
 */
public ZstdCompressorOutputStream(final OutputStream outStream, int level, boolean closeFrameOnFlush,
  boolean useChecksum) throws IOException {
  this.encOS = new ZstdOutputStream(outStream, level, closeFrameOnFlush, useChecksum);
}

代码示例来源:origin: usethesource/rascal

private static final OutputStream getOutputStream(String compressionMethod, OutputStream original) throws IOException, CompressorException {
  if (compressionMethod == ZSTD_COMPRESSION) {
    return new ZstdOutputStream(original);
  }
  return new CompressorStreamFactory().createCompressorOutputStream(compressionMethod, original);
}

代码示例来源:origin: org.apache.carbondata/carbondata-core

@Override
public DataOutputStream getDataOutputStream(String path, FileFactory.FileType fileType,
  int bufferSize, String compressor) throws IOException {
 path = path.replace("\\", "/");
 path = FileFactory.getUpdatedFilePath(path, fileType);
 OutputStream outputStream;
 if (compressor.isEmpty()) {
  outputStream = new FileOutputStream(path);
 } else if ("GZIP".equalsIgnoreCase(compressor)) {
  outputStream = new GZIPOutputStream(new FileOutputStream(path));
 } else if ("BZIP2".equalsIgnoreCase(compressor)) {
  outputStream = new BZip2CompressorOutputStream(new FileOutputStream(path));
 } else if ("SNAPPY".equalsIgnoreCase(compressor)) {
  outputStream = new SnappyOutputStream(new FileOutputStream(path));
 } else if ("LZ4".equalsIgnoreCase(compressor)) {
  outputStream = new LZ4BlockOutputStream(new FileOutputStream(path));
 } else if ("ZSTD".equalsIgnoreCase(compressor)) {
  // compression level 1 is cost-effective for sort temp file
  // which is not used for storage
  outputStream = new ZstdOutputStream(new FileOutputStream(path), 1);
 } else {
  throw new IOException("Unsupported compressor: " + compressor);
 }
 if (bufferSize <= 0) {
  return new DataOutputStream(new BufferedOutputStream(outputStream));
 } else {
  return new DataOutputStream(new BufferedOutputStream(outputStream, bufferSize));
 }
}

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com