gpt4 book ai didi

io.netty.handler.codec.compression.ZlibUtil类的使用及代码示例

转载 作者:知者 更新时间:2024-03-15 12:11:31 26 4
gpt4 key购买 nike

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

ZlibUtil介绍

[英]Utility methods used by JZlibEncoder and JZlibDecoder.
[中]JZlibEncoder和JZlibDecoder使用的实用方法。

代码示例

代码示例来源:origin: netty/netty

ZlibUtil.convertWrapperType(wrapper));
if (resultCode != JZlib.Z_OK) {
  ZlibUtil.fail(z, "initialization failure", resultCode);
wrapperOverhead = ZlibUtil.wrapperOverhead(wrapper);

代码示例来源:origin: netty/netty

static void fail(Deflater z, String message, int resultCode) {
  throw deflaterException(z, message, resultCode);
}

代码示例来源:origin: netty/netty

static void fail(Inflater z, String message, int resultCode) {
  throw inflaterException(z, message, resultCode);
}

代码示例来源:origin: netty/netty

/**
 * Creates a new instance with the specified wrapper.
 *
 * @throws DecompressionException if failed to initialize zlib
 */
public JZlibDecoder(ZlibWrapper wrapper) {
  if (wrapper == null) {
    throw new NullPointerException("wrapper");
  }
  int resultCode = z.init(ZlibUtil.convertWrapperType(wrapper));
  if (resultCode != JZlib.Z_OK) {
    ZlibUtil.fail(z, "initialization failure", resultCode);
  }
}

代码示例来源:origin: netty/netty

ZlibUtil.fail(z, "initialization failure", resultCode);
} else {
  resultCode = z.deflateSetDictionary(dictionary, dictionary.length);
  if (resultCode != JZlib.Z_OK) {
    ZlibUtil.fail(z, "failed to set the dictionary", resultCode);
wrapperOverhead = ZlibUtil.wrapperOverhead(ZlibWrapper.ZLIB);

代码示例来源:origin: netty/netty

/**
 * Creates a new instance with the specified preset dictionary. The wrapper
 * is always {@link ZlibWrapper#ZLIB} because it is the only format that
 * supports the preset dictionary.
 *
 * @throws DecompressionException if failed to initialize zlib
 */
public JZlibDecoder(byte[] dictionary) {
  if (dictionary == null) {
    throw new NullPointerException("dictionary");
  }
  this.dictionary = dictionary;
  int resultCode;
  resultCode = z.inflateInit(JZlib.W_ZLIB);
  if (resultCode != JZlib.Z_OK) {
    ZlibUtil.fail(z, "initialization failure", resultCode);
  }
}

代码示例来源:origin: redisson/redisson

/**
 * Creates a new instance with the specified wrapper.
 *
 * @throws DecompressionException if failed to initialize zlib
 */
public JZlibDecoder(ZlibWrapper wrapper) {
  if (wrapper == null) {
    throw new NullPointerException("wrapper");
  }
  int resultCode = z.init(ZlibUtil.convertWrapperType(wrapper));
  if (resultCode != JZlib.Z_OK) {
    ZlibUtil.fail(z, "initialization failure", resultCode);
  }
}

代码示例来源:origin: redisson/redisson

ZlibUtil.fail(z, "initialization failure", resultCode);
} else {
  resultCode = z.deflateSetDictionary(dictionary, dictionary.length);
  if (resultCode != JZlib.Z_OK) {
    ZlibUtil.fail(z, "failed to set the dictionary", resultCode);
wrapperOverhead = ZlibUtil.wrapperOverhead(ZlibWrapper.ZLIB);

代码示例来源:origin: redisson/redisson

/**
 * Creates a new instance with the specified preset dictionary. The wrapper
 * is always {@link ZlibWrapper#ZLIB} because it is the only format that
 * supports the preset dictionary.
 *
 * @throws DecompressionException if failed to initialize zlib
 */
public JZlibDecoder(byte[] dictionary) {
  if (dictionary == null) {
    throw new NullPointerException("dictionary");
  }
  this.dictionary = dictionary;
  int resultCode;
  resultCode = z.inflateInit(JZlib.W_ZLIB);
  if (resultCode != JZlib.Z_OK) {
    ZlibUtil.fail(z, "initialization failure", resultCode);
  }
}

代码示例来源:origin: redisson/redisson

ZlibUtil.convertWrapperType(wrapper));
if (resultCode != JZlib.Z_OK) {
  ZlibUtil.fail(z, "initialization failure", resultCode);
wrapperOverhead = ZlibUtil.wrapperOverhead(wrapper);

代码示例来源:origin: wildfly/wildfly

/**
 * Creates a new instance with the specified wrapper.
 *
 * @throws DecompressionException if failed to initialize zlib
 */
public JZlibDecoder(ZlibWrapper wrapper) {
  if (wrapper == null) {
    throw new NullPointerException("wrapper");
  }
  int resultCode = z.init(ZlibUtil.convertWrapperType(wrapper));
  if (resultCode != JZlib.Z_OK) {
    ZlibUtil.fail(z, "initialization failure", resultCode);
  }
}

代码示例来源:origin: wildfly/wildfly

ZlibUtil.fail(z, "initialization failure", resultCode);
} else {
  resultCode = z.deflateSetDictionary(dictionary, dictionary.length);
  if (resultCode != JZlib.Z_OK) {
    ZlibUtil.fail(z, "failed to set the dictionary", resultCode);
wrapperOverhead = ZlibUtil.wrapperOverhead(ZlibWrapper.ZLIB);

代码示例来源:origin: wildfly/wildfly

/**
 * Creates a new instance with the specified preset dictionary. The wrapper
 * is always {@link ZlibWrapper#ZLIB} because it is the only format that
 * supports the preset dictionary.
 *
 * @throws DecompressionException if failed to initialize zlib
 */
public JZlibDecoder(byte[] dictionary) {
  if (dictionary == null) {
    throw new NullPointerException("dictionary");
  }
  this.dictionary = dictionary;
  int resultCode;
  resultCode = z.inflateInit(JZlib.W_ZLIB);
  if (resultCode != JZlib.Z_OK) {
    ZlibUtil.fail(z, "initialization failure", resultCode);
  }
}

代码示例来源:origin: redisson/redisson

static void fail(Deflater z, String message, int resultCode) {
  throw deflaterException(z, message, resultCode);
}

代码示例来源:origin: redisson/redisson

static void fail(Inflater z, String message, int resultCode) {
  throw inflaterException(z, message, resultCode);
}

代码示例来源:origin: wildfly/wildfly

ZlibUtil.convertWrapperType(wrapper));
if (resultCode != JZlib.Z_OK) {
  ZlibUtil.fail(z, "initialization failure", resultCode);
wrapperOverhead = ZlibUtil.wrapperOverhead(wrapper);

代码示例来源:origin: org.jboss.eap/wildfly-client-all

/**
 * Creates a new instance with the specified wrapper.
 *
 * @throws DecompressionException if failed to initialize zlib
 */
public JZlibDecoder(ZlibWrapper wrapper) {
  if (wrapper == null) {
    throw new NullPointerException("wrapper");
  }
  int resultCode = z.init(ZlibUtil.convertWrapperType(wrapper));
  if (resultCode != JZlib.Z_OK) {
    ZlibUtil.fail(z, "initialization failure", resultCode);
  }
}

代码示例来源:origin: io.netty/netty-codec

ZlibUtil.fail(z, "initialization failure", resultCode);
} else {
  resultCode = z.deflateSetDictionary(dictionary, dictionary.length);
  if (resultCode != JZlib.Z_OK) {
    ZlibUtil.fail(z, "failed to set the dictionary", resultCode);
wrapperOverhead = ZlibUtil.wrapperOverhead(ZlibWrapper.ZLIB);

代码示例来源:origin: netty/netty

ZlibUtil.fail(z, "compression failure", resultCode);

代码示例来源:origin: wildfly/wildfly

static void fail(Deflater z, String message, int resultCode) {
  throw deflaterException(z, message, resultCode);
}

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