本文整理了Java中org.apache.hadoop.hbase.util.Bytes.putFloat()
方法的一些代码示例,展示了Bytes.putFloat()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Bytes.putFloat()
方法的具体详情如下:
包路径:org.apache.hadoop.hbase.util.Bytes
类名称:Bytes
方法名:putFloat
暂无
代码示例来源:origin: apache/hbase
/**
* Write instance {@code val} into buffer {@code buff}.
*/
public int encodeFloat(byte[] buff, int offset, float val) {
return Bytes.putFloat(buff, offset, val);
}
}
代码示例来源:origin: alibaba/canal
private static int encodeUnsignedFloat(float v, byte[] b, int o) {
checkForSufficientLength(b, o, Bytes.SIZEOF_FLOAT);
if (v < 0) {
throw new RuntimeException();
}
Bytes.putFloat(b, o, v);
return Bytes.SIZEOF_FLOAT;
}
代码示例来源:origin: apache/hbase
@Override
public int encode(PositionedByteRange dst, Float val) {
Bytes.putFloat(dst.getBytes(), dst.getOffset() + dst.getPosition(), val);
return skip(dst);
}
代码示例来源:origin: forcedotcom/phoenix
@Override
public int encodeFloat(float v, byte[] b, int o) {
if (v < 0) {
throw new IllegalDataException();
}
Bytes.putFloat(b, o, v);
return Bytes.SIZEOF_FLOAT;
}
代码示例来源:origin: apache/phoenix
@Override
public int encodeFloat(float v, byte[] b, int o) {
checkForSufficientLength(b, o, Bytes.SIZEOF_FLOAT);
if (v < 0) {
throw newIllegalDataException();
}
Bytes.putFloat(b, o, v);
return Bytes.SIZEOF_FLOAT;
}
代码示例来源:origin: org.apache.hbase/hbase-common
/**
* Write instance {@code val} into buffer {@code buff}.
*/
public int encodeFloat(byte[] buff, int offset, float val) {
return Bytes.putFloat(buff, offset, val);
}
}
代码示例来源:origin: com.aliyun.hbase/alihbase-common
/**
* Write instance {@code val} into buffer {@code buff}.
*/
public int encodeFloat(byte[] buff, int offset, float val) {
return Bytes.putFloat(buff, offset, val);
}
}
代码示例来源:origin: dbs-leipzig/gradoop
/**
* Sets the wrapped value as {@code float} value.
*
* @param floatValue value
*/
public void setFloat(float floatValue) {
rawBytes = new byte[OFFSET + Bytes.SIZEOF_FLOAT];
rawBytes[0] = TYPE_FLOAT;
Bytes.putFloat(rawBytes, OFFSET, floatValue);
}
/**
代码示例来源:origin: harbby/presto-connectors
/**
* Write instance {@code val} into buffer {@code buff}.
*/
public int encodeFloat(byte[] buff, int offset, float val) {
return Bytes.putFloat(buff, offset, val);
}
}
代码示例来源:origin: org.apache.phoenix/phoenix-core
@Override
public int encodeFloat(float v, byte[] b, int o) {
checkForSufficientLength(b, o, Bytes.SIZEOF_FLOAT);
if (v < 0) {
throw newIllegalDataException();
}
Bytes.putFloat(b, o, v);
return Bytes.SIZEOF_FLOAT;
}
代码示例来源:origin: com.aliyun.phoenix/ali-phoenix-core
@Override
public int encodeFloat(float v, byte[] b, int o) {
checkForSufficientLength(b, o, Bytes.SIZEOF_FLOAT);
if (v < 0) {
throw newIllegalDataException();
}
Bytes.putFloat(b, o, v);
return Bytes.SIZEOF_FLOAT;
}
代码示例来源:origin: org.apache.hbase/hbase-common
@Override
public int encode(PositionedByteRange dst, Float val) {
Bytes.putFloat(dst.getBytes(), dst.getOffset() + dst.getPosition(), val);
return skip(dst);
}
代码示例来源:origin: com.aliyun.hbase/alihbase-common
@Override
public int encode(PositionedByteRange dst, Float val) {
Bytes.putFloat(dst.getBytes(), dst.getOffset() + dst.getPosition(), val);
return skip(dst);
}
代码示例来源:origin: harbby/presto-connectors
@Override
public int encode(PositionedByteRange dst, Float val) {
Bytes.putFloat(dst.getBytes(), dst.getOffset() + dst.getPosition(), val);
return skip(dst);
}
内容来源于网络,如有侵权,请联系作者删除!