org.apache.hadoop.hbase.client.Increment.createPutKeyValue()方法的使用及代码示例

x33g5p2x  于2022-01-21 转载在 其他  
字(2.9k)|赞(0)|评价(0)|浏览(146)

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

Increment.createPutKeyValue介绍

暂无

代码示例

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

/**
 * Increment the column from the specific family with the specified qualifier
 * by the specified amount.
 * <p>
 * Overrides previous calls to addColumn for this family and qualifier.
 * @param family family name
 * @param qualifier column qualifier
 * @param amount amount to increment by
 * @return the Increment object
 */
public Increment addColumn(byte [] family, byte [] qualifier, long amount) {
 if (family == null) {
  throw new IllegalArgumentException("family cannot be null");
 }
 List<Cell> list = getCellList(family);
 KeyValue kv = createPutKeyValue(family, qualifier, ts, Bytes.toBytes(amount));
 list.add(kv);
 return this;
}

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

/**
 * Increment the column from the specific family with the specified qualifier
 * by the specified amount.
 * <p>
 * Overrides previous calls to addColumn for this family and qualifier.
 * @param family family name
 * @param qualifier column qualifier
 * @param amount amount to increment by
 * @return the Increment object
 */
public Increment addColumn(byte [] family, byte [] qualifier, long amount) {
 if (family == null) {
  throw new IllegalArgumentException("family cannot be null");
 }
 List<Cell> list = getCellList(family);
 KeyValue kv = createPutKeyValue(family, qualifier, ts, Bytes.toBytes(amount));
 list.add(kv);
 return this;
}

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

/**
 * Increment the column from the specific family with the specified qualifier
 * by the specified amount.
 * <p>
 * Overrides previous calls to addColumn for this family and qualifier.
 * @param family family name
 * @param qualifier column qualifier
 * @param amount amount to increment by
 * @return the Increment object
 */
public Increment addColumn(byte [] family, byte [] qualifier, long amount) {
 if (family == null) {
  throw new IllegalArgumentException("family cannot be null");
 }
 List<Cell> list = getCellList(family);
 KeyValue kv = createPutKeyValue(family, qualifier, ts, Bytes.toBytes(amount));
 list.add(kv);
 return this;
}

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

/**
 * Increment the column from the specific family with the specified qualifier
 * by the specified amount.
 * <p>
 * Overrides previous calls to addColumn for this family and qualifier.
 * @param family family name
 * @param qualifier column qualifier
 * @param amount amount to increment by
 * @return the Increment object
 */
public Increment addColumn(byte [] family, byte [] qualifier, long amount) {
 if (family == null) {
  throw new IllegalArgumentException("family cannot be null");
 }
 if (qualifier == null) {
  throw new IllegalArgumentException("qualifier cannot be null");
 }
 List<Cell> list = getCellList(family);
 KeyValue kv = createPutKeyValue(family, qualifier, ts, Bytes.toBytes(amount));
 list.add(kv);
 familyMap.put(CellUtil.cloneFamily(kv), list);
 return this;
}

相关文章