本文整理了Java中com.esotericsoftware.kryo.io.Output.writeVarLong()
方法的一些代码示例,展示了Output.writeVarLong()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Output.writeVarLong()
方法的具体详情如下:
包路径:com.esotericsoftware.kryo.io.Output
类名称:Output
方法名:writeVarLong
[英]Writes a 1-9 byte long. It is guaranteed that a varible length encoding will be used.
[中]
代码示例来源:origin: com.esotericsoftware/kryo
/** Writes a 1-9 byte long. This stream may consider such a variable length encoding request as a hint. It is not guaranteed
* that a variable length encoding will be really used. The stream may decide to use native-sized integer representation for
* efficiency reasons.
*
* @param optimizePositive If true, small positive numbers will be more efficient (1 byte) and small negative numbers will be
* inefficient (9 bytes). */
public int writeLong (long value, boolean optimizePositive) throws KryoException {
return writeVarLong(value, optimizePositive);
}
代码示例来源:origin: com.esotericsoftware.kryo/kryo
/** Writes a 1-9 byte long. This stream may consider such a variable length encoding request as a hint. It is not guaranteed
* that a variable length encoding will be really used. The stream may decide to use native-sized integer representation for
* efficiency reasons.
*
* @param optimizePositive If true, small positive numbers will be more efficient (1 byte) and small negative numbers will be
* inefficient (9 bytes). */
public int writeLong (long value, boolean optimizePositive) throws KryoException {
return writeVarLong(value, optimizePositive);
}
代码示例来源:origin: com.esotericsoftware/kryo-shaded
/** Writes a 1-9 byte long. This stream may consider such a variable length encoding request as a hint. It is not guaranteed
* that a variable length encoding will be really used. The stream may decide to use native-sized integer representation for
* efficiency reasons.
*
* @param optimizePositive If true, small positive numbers will be more efficient (1 byte) and small negative numbers will be
* inefficient (9 bytes). */
public int writeLong (long value, boolean optimizePositive) throws KryoException {
return writeVarLong(value, optimizePositive);
}
代码示例来源:origin: svn2github/kryo
/** Writes a 1-9 byte long. This stream may consider such a variable length encoding request as a hint. It is not guaranteed
* that a variable length encoding will be really used. The stream may decide to use native-sized integer representation for
* efficiency reasons.
*
* @param optimizePositive If true, small positive numbers will be more efficient (1 byte) and small negative numbers will be
* inefficient (9 bytes). */
public int writeLong (long value, boolean optimizePositive) throws KryoException {
return writeVarLong(value, optimizePositive);
}
内容来源于网络,如有侵权,请联系作者删除!