org.apache.hadoop.hbase.util.Bytes.putDouble()方法的使用及代码示例

x33g5p2x  于2022-01-16 转载在 其他  
字(3.1k)|赞(0)|评价(0)|浏览(75)

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

Bytes.putDouble介绍

暂无

代码示例

代码示例来源:origin: apache/hbase

/**
  * Write instance {@code val} into buffer {@code buff}.
  */
 public int encodeDouble(byte[] buff, int offset, double val) {
  return Bytes.putDouble(buff, offset, val);
 }
}

代码示例来源:origin: alibaba/canal

private static int encodeUnsignedDouble(double v, byte[] b, int o) {
  checkForSufficientLength(b, o, Bytes.SIZEOF_DOUBLE);
  if (v < 0) {
    throw new RuntimeException();
  }
  Bytes.putDouble(b, o, v);
  return Bytes.SIZEOF_DOUBLE;
}

代码示例来源:origin: apache/hbase

@Override
public int encode(PositionedByteRange dst, Double val) {
 Bytes.putDouble(dst.getBytes(), dst.getOffset() + dst.getPosition(), val);
 return skip(dst);
}

代码示例来源:origin: forcedotcom/phoenix

@Override
public int encodeDouble(double v, byte[] b, int o) {
  if (v < 0) {
    throw new IllegalDataException();
  }
  Bytes.putDouble(b, o, v);
  return Bytes.SIZEOF_DOUBLE;
}

代码示例来源:origin: apache/phoenix

@Override
public int encodeDouble(double v, byte[] b, int o) {
  checkForSufficientLength(b, o, Bytes.SIZEOF_DOUBLE);
  if (v < 0) {
    throw newIllegalDataException();
  }
  Bytes.putDouble(b, o, v);
  return Bytes.SIZEOF_DOUBLE;
}

代码示例来源:origin: org.apache.hbase/hbase-common

/**
  * Write instance {@code val} into buffer {@code buff}.
  */
 public int encodeDouble(byte[] buff, int offset, double val) {
  return Bytes.putDouble(buff, offset, val);
 }
}

代码示例来源:origin: com.aliyun.hbase/alihbase-common

/**
  * Write instance {@code val} into buffer {@code buff}.
  */
 public int encodeDouble(byte[] buff, int offset, double val) {
  return Bytes.putDouble(buff, offset, val);
 }
}

代码示例来源:origin: harbby/presto-connectors

/**
  * Write instance {@code val} into buffer {@code buff}.
  */
 public int encodeDouble(byte[] buff, int offset, double val) {
  return Bytes.putDouble(buff, offset, val);
 }
}

代码示例来源:origin: dbs-leipzig/gradoop

/**
 * Sets the wrapped value as {@code double} value.
 *
 * @param doubleValue value
 */
public void setDouble(double doubleValue) {
 rawBytes = new byte[OFFSET + Bytes.SIZEOF_DOUBLE];
 rawBytes[0] = TYPE_DOUBLE;
 Bytes.putDouble(rawBytes, OFFSET, doubleValue);
}
/**

代码示例来源:origin: com.aliyun.phoenix/ali-phoenix-core

@Override
public int encodeDouble(double v, byte[] b, int o) {
  checkForSufficientLength(b, o, Bytes.SIZEOF_DOUBLE);
  if (v < 0) {
    throw newIllegalDataException();
  }
  Bytes.putDouble(b, o, v);
  return Bytes.SIZEOF_DOUBLE;
}

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

@Override
public int encodeDouble(double v, byte[] b, int o) {
  checkForSufficientLength(b, o, Bytes.SIZEOF_DOUBLE);
  if (v < 0) {
    throw newIllegalDataException();
  }
  Bytes.putDouble(b, o, v);
  return Bytes.SIZEOF_DOUBLE;
}

代码示例来源:origin: org.apache.hbase/hbase-common

@Override
public int encode(PositionedByteRange dst, Double val) {
 Bytes.putDouble(dst.getBytes(), dst.getOffset() + dst.getPosition(), val);
 return skip(dst);
}

代码示例来源:origin: com.aliyun.hbase/alihbase-common

@Override
public int encode(PositionedByteRange dst, Double val) {
 Bytes.putDouble(dst.getBytes(), dst.getOffset() + dst.getPosition(), val);
 return skip(dst);
}

代码示例来源:origin: harbby/presto-connectors

@Override
public int encode(PositionedByteRange dst, Double val) {
 Bytes.putDouble(dst.getBytes(), dst.getOffset() + dst.getPosition(), val);
 return skip(dst);
}

相关文章

微信公众号

最新文章

更多