本文整理了Java中com.esotericsoftware.kryo.io.Input.readDoubles()
方法的一些代码示例,展示了Input.readDoubles()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Input.readDoubles()
方法的具体详情如下:
包路径:com.esotericsoftware.kryo.io.Input
类名称:Input
方法名:readDoubles
[英]Bulk input of a double array.
[中]双数组的大容量输入。
代码示例来源:origin: com.esotericsoftware/kryo
/** Bulk input of a double array. */
public double[] readDoubles (int length) throws KryoException {
if (capacity - position >= length * 8 && isNativeOrder()) {
double[] array = new double[length];
DoubleBuffer buf = niobuffer.asDoubleBuffer();
buf.get(array);
position += length * 8;
niobuffer.position(position);
return array;
} else
return super.readDoubles(length);
}
代码示例来源:origin: com.esotericsoftware/kryo
public double[] read (Kryo kryo, Input input, Class<double[]> type) {
int length = input.readVarInt(true);
if (length == NULL) return null;
return input.readDoubles(length - 1);
}
代码示例来源:origin: com.esotericsoftware.kryo/kryo
/** Bulk input of a double array. */
public double[] readDoubles (int length) throws KryoException {
if (capacity - position >= length * 8 && isNativeOrder()) {
double[] array = new double[length];
DoubleBuffer buf = niobuffer.asDoubleBuffer();
buf.get(array);
position += length * 8;
niobuffer.position(position);
return array;
} else
return super.readDoubles(length);
}
代码示例来源:origin: com.esotericsoftware.kryo/kryo
public double[] read (Kryo kryo, Input input, Class<double[]> type) {
int length = input.readVarInt(true);
if (length == NULL) return null;
return input.readDoubles(length-1);
}
代码示例来源:origin: svn2github/kryo
public double[] read (Kryo kryo, Input input, Class<double[]> type) {
int length = input.readVarInt(true);
if (length == NULL) return null;
return input.readDoubles(length-1);
}
代码示例来源:origin: com.esotericsoftware/kryo-shaded
public double[] read (Kryo kryo, Input input, Class<double[]> type) {
int length = input.readVarInt(true);
if (length == NULL) return null;
return input.readDoubles(length - 1);
}
代码示例来源:origin: com.esotericsoftware/kryo-shaded
/** Bulk input of a double array. */
public double[] readDoubles (int length) throws KryoException {
if (capacity - position >= length * 8 && isNativeOrder()) {
double[] array = new double[length];
DoubleBuffer buf = niobuffer.asDoubleBuffer();
buf.get(array);
position += length * 8;
niobuffer.position(position);
return array;
} else
return super.readDoubles(length);
}
代码示例来源:origin: svn2github/kryo
/** Bulk input of a double array. */
public double[] readDoubles (int length) throws KryoException {
if (capacity - position >= length * 8 && isNativeOrder()) {
double[] array = new double[length];
DoubleBuffer buf = niobuffer.asDoubleBuffer();
buf.get(array);
position += length * 8;
niobuffer.position(position);
return array;
} else
return super.readDoubles(length);
}
代码示例来源:origin: apache/apex-malhar
case "double":
NDArray<double[]> doubleNDArray = new NDArray<>(
input.readDoubles(singleDimensionArrayLength),signedFlag,dimensions);
return doubleNDArray;
case "long":
内容来源于网络,如有侵权,请联系作者删除!