Tabnine Logo
CellProtos$Cell$Builder.setRow
Code IndexAdd Tabnine to your IDE (free)

How to use
setRow
method
in
org.apache.hadoop.hbase.shaded.protobuf.generated.CellProtos$Cell$Builder

Best Java code snippets using org.apache.hadoop.hbase.shaded.protobuf.generated.CellProtos$Cell$Builder.setRow (Showing top 8 results out of 315)

origin: apache/hbase

static CellProtos.Cell.Builder getBaseCellBuilder(final ByteString row) {
 CellProtos.Cell.Builder cellBuilder = CellProtos.Cell.newBuilder();
 cellBuilder.setRow(row);
 cellBuilder.setFamily(CATALOG_FAMILY_BYTESTRING);
 cellBuilder.setTimestamp(System.currentTimeMillis());
 return cellBuilder;
}
origin: org.apache.hbase/hbase-client

static CellProtos.Cell.Builder getBaseCellBuilder(final ByteString row) {
 CellProtos.Cell.Builder cellBuilder = CellProtos.Cell.newBuilder();
 cellBuilder.setRow(row);
 cellBuilder.setFamily(CATALOG_FAMILY_BYTESTRING);
 cellBuilder.setTimestamp(System.currentTimeMillis());
 return cellBuilder;
}
origin: com.aliyun.hbase/alihbase-client

public static CellProtos.Cell toCell(final Cell kv) {
 // Doing this is going to kill us if we do it for all data passed.
 // St.Ack 20121205
 CellProtos.Cell.Builder kvbuilder = CellProtos.Cell.newBuilder();
 if (kv instanceof ByteBufferExtendedCell) {
  kvbuilder.setRow(wrap(((ByteBufferExtendedCell) kv).getRowByteBuffer(),
   ((ByteBufferExtendedCell) kv).getRowPosition(), kv.getRowLength()));
  kvbuilder.setFamily(wrap(((ByteBufferExtendedCell) kv).getFamilyByteBuffer(),
   ((ByteBufferExtendedCell) kv).getFamilyPosition(), kv.getFamilyLength()));
  kvbuilder.setQualifier(wrap(((ByteBufferExtendedCell) kv).getQualifierByteBuffer(),
   ((ByteBufferExtendedCell) kv).getQualifierPosition(), kv.getQualifierLength()));
  kvbuilder.setCellType(CellProtos.CellType.valueOf(kv.getTypeByte()));
  kvbuilder.setTimestamp(kv.getTimestamp());
  kvbuilder.setValue(wrap(((ByteBufferExtendedCell) kv).getValueByteBuffer(),
   ((ByteBufferExtendedCell) kv).getValuePosition(), kv.getValueLength()));
  // TODO : Once tags become first class then we may have to set tags to kvbuilder.
 } else {
  kvbuilder.setRow(
   UnsafeByteOperations.unsafeWrap(kv.getRowArray(), kv.getRowOffset(), kv.getRowLength()));
  kvbuilder.setFamily(UnsafeByteOperations.unsafeWrap(kv.getFamilyArray(), kv.getFamilyOffset(),
   kv.getFamilyLength()));
  kvbuilder.setQualifier(UnsafeByteOperations.unsafeWrap(kv.getQualifierArray(),
   kv.getQualifierOffset(), kv.getQualifierLength()));
  kvbuilder.setCellType(CellProtos.CellType.valueOf(kv.getTypeByte()));
  kvbuilder.setTimestamp(kv.getTimestamp());
  kvbuilder.setValue(UnsafeByteOperations.unsafeWrap(kv.getValueArray(), kv.getValueOffset(),
   kv.getValueLength()));
 }
 return kvbuilder.build();
}
origin: org.apache.hbase/hbase-protocol-shaded

public Builder mergeFrom(org.apache.hadoop.hbase.shaded.protobuf.generated.CellProtos.Cell other) {
 if (other == org.apache.hadoop.hbase.shaded.protobuf.generated.CellProtos.Cell.getDefaultInstance()) return this;
 if (other.hasRow()) {
  setRow(other.getRow());
 }
 if (other.hasFamily()) {
  setFamily(other.getFamily());
 }
 if (other.hasQualifier()) {
  setQualifier(other.getQualifier());
 }
 if (other.hasTimestamp()) {
  setTimestamp(other.getTimestamp());
 }
 if (other.hasCellType()) {
  setCellType(other.getCellType());
 }
 if (other.hasValue()) {
  setValue(other.getValue());
 }
 if (other.hasTags()) {
  setTags(other.getTags());
 }
 this.mergeUnknownFields(other.unknownFields);
 onChanged();
 return this;
}
origin: org.apache.hbase/hbase-client

public static CellProtos.Cell toCell(final Cell kv) {
 // Doing this is going to kill us if we do it for all data passed.
 // St.Ack 20121205
 CellProtos.Cell.Builder kvbuilder = CellProtos.Cell.newBuilder();
 if (kv instanceof ByteBufferExtendedCell) {
  kvbuilder.setRow(wrap(((ByteBufferExtendedCell) kv).getRowByteBuffer(),
   ((ByteBufferExtendedCell) kv).getRowPosition(), kv.getRowLength()));
  kvbuilder.setFamily(wrap(((ByteBufferExtendedCell) kv).getFamilyByteBuffer(),
   ((ByteBufferExtendedCell) kv).getFamilyPosition(), kv.getFamilyLength()));
  kvbuilder.setQualifier(wrap(((ByteBufferExtendedCell) kv).getQualifierByteBuffer(),
   ((ByteBufferExtendedCell) kv).getQualifierPosition(), kv.getQualifierLength()));
  kvbuilder.setCellType(CellProtos.CellType.valueOf(kv.getTypeByte()));
  kvbuilder.setTimestamp(kv.getTimestamp());
  kvbuilder.setValue(wrap(((ByteBufferExtendedCell) kv).getValueByteBuffer(),
   ((ByteBufferExtendedCell) kv).getValuePosition(), kv.getValueLength()));
  // TODO : Once tags become first class then we may have to set tags to kvbuilder.
 } else {
  kvbuilder.setRow(
   UnsafeByteOperations.unsafeWrap(kv.getRowArray(), kv.getRowOffset(), kv.getRowLength()));
  kvbuilder.setFamily(UnsafeByteOperations.unsafeWrap(kv.getFamilyArray(), kv.getFamilyOffset(),
   kv.getFamilyLength()));
  kvbuilder.setQualifier(UnsafeByteOperations.unsafeWrap(kv.getQualifierArray(),
   kv.getQualifierOffset(), kv.getQualifierLength()));
  kvbuilder.setCellType(CellProtos.CellType.valueOf(kv.getTypeByte()));
  kvbuilder.setTimestamp(kv.getTimestamp());
  kvbuilder.setValue(UnsafeByteOperations.unsafeWrap(kv.getValueArray(), kv.getValueOffset(),
   kv.getValueLength()));
 }
 return kvbuilder.build();
}
origin: apache/hbase

public static CellProtos.Cell toCell(final Cell kv) {
 // Doing this is going to kill us if we do it for all data passed.
 // St.Ack 20121205
 CellProtos.Cell.Builder kvbuilder = CellProtos.Cell.newBuilder();
 if (kv instanceof ByteBufferExtendedCell) {
  kvbuilder.setRow(wrap(((ByteBufferExtendedCell) kv).getRowByteBuffer(),
   ((ByteBufferExtendedCell) kv).getRowPosition(), kv.getRowLength()));
  kvbuilder.setFamily(wrap(((ByteBufferExtendedCell) kv).getFamilyByteBuffer(),
   ((ByteBufferExtendedCell) kv).getFamilyPosition(), kv.getFamilyLength()));
  kvbuilder.setQualifier(wrap(((ByteBufferExtendedCell) kv).getQualifierByteBuffer(),
   ((ByteBufferExtendedCell) kv).getQualifierPosition(), kv.getQualifierLength()));
  kvbuilder.setCellType(CellProtos.CellType.valueOf(kv.getTypeByte()));
  kvbuilder.setTimestamp(kv.getTimestamp());
  kvbuilder.setValue(wrap(((ByteBufferExtendedCell) kv).getValueByteBuffer(),
   ((ByteBufferExtendedCell) kv).getValuePosition(), kv.getValueLength()));
  // TODO : Once tags become first class then we may have to set tags to kvbuilder.
 } else {
  kvbuilder.setRow(
   UnsafeByteOperations.unsafeWrap(kv.getRowArray(), kv.getRowOffset(), kv.getRowLength()));
  kvbuilder.setFamily(UnsafeByteOperations.unsafeWrap(kv.getFamilyArray(), kv.getFamilyOffset(),
   kv.getFamilyLength()));
  kvbuilder.setQualifier(UnsafeByteOperations.unsafeWrap(kv.getQualifierArray(),
   kv.getQualifierOffset(), kv.getQualifierLength()));
  kvbuilder.setCellType(CellProtos.CellType.valueOf(kv.getTypeByte()));
  kvbuilder.setTimestamp(kv.getTimestamp());
  kvbuilder.setValue(UnsafeByteOperations.unsafeWrap(kv.getValueArray(), kv.getValueOffset(),
   kv.getValueLength()));
 }
 return kvbuilder.build();
}
origin: apache/hbase

public Builder mergeFrom(org.apache.hadoop.hbase.shaded.protobuf.generated.CellProtos.Cell other) {
 if (other == org.apache.hadoop.hbase.shaded.protobuf.generated.CellProtos.Cell.getDefaultInstance()) return this;
 if (other.hasRow()) {
  setRow(other.getRow());
 }
 if (other.hasFamily()) {
  setFamily(other.getFamily());
 }
 if (other.hasQualifier()) {
  setQualifier(other.getQualifier());
 }
 if (other.hasTimestamp()) {
  setTimestamp(other.getTimestamp());
 }
 if (other.hasCellType()) {
  setCellType(other.getCellType());
 }
 if (other.hasValue()) {
  setValue(other.getValue());
 }
 if (other.hasTags()) {
  setTags(other.getTags());
 }
 this.mergeUnknownFields(other.unknownFields);
 onChanged();
 return this;
}
origin: apache/hbase

 @Override
 public void write(Cell cell) throws IOException {
  checkFlushed();
  CellProtos.Cell.Builder builder = CellProtos.Cell.newBuilder();
  // This copies bytes from Cell to ByteString.  I don't see anyway around the copy.
  // ByteString is final.
  builder.setRow(UnsafeByteOperations.unsafeWrap(cell.getRowArray(), cell.getRowOffset(),
    cell.getRowLength()));
  builder.setFamily(UnsafeByteOperations.unsafeWrap(cell.getFamilyArray(),
    cell.getFamilyOffset(),
    cell.getFamilyLength()));
  builder.setQualifier(UnsafeByteOperations.unsafeWrap(cell.getQualifierArray(),
    cell.getQualifierOffset(), cell.getQualifierLength()));
  builder.setTimestamp(cell.getTimestamp());
  builder.setCellType(CellProtos.CellType.valueOf(cell.getTypeByte()));
  builder.setValue(UnsafeByteOperations.unsafeWrap(cell.getValueArray(), cell.getValueOffset(),
    cell.getValueLength()));
  CellProtos.Cell pbcell = builder.build();
  pbcell.writeDelimitedTo(this.out);
 }
}
org.apache.hadoop.hbase.shaded.protobuf.generatedCellProtos$Cell$BuildersetRow

Javadoc

optional bytes row = 1;

Popular methods of CellProtos$Cell$Builder

  • setFamily
    optional bytes family = 2;
  • setQualifier
    optional bytes qualifier = 3;
  • setTimestamp
    optional uint64 timestamp = 4;
  • setValue
    optional bytes value = 6;
  • build
  • setCellType
    optional .hbase.pb.CellType cell_type = 5;
  • <init>
  • buildPartial
  • maybeForceBuilderInitialization
  • mergeFrom
  • mergeUnknownFields
  • newUninitializedMessageException
  • mergeUnknownFields,
  • newUninitializedMessageException,
  • onBuilt,
  • onChanged,
  • setTags

Popular in Java

  • Running tasks concurrently on multiple threads
  • getApplicationContext (Context)
  • getResourceAsStream (ClassLoader)
  • orElseThrow (Optional)
    Return the contained value, if present, otherwise throw an exception to be created by the provided s
  • Menu (java.awt)
  • FileWriter (java.io)
    A specialized Writer that writes to a file in the file system. All write requests made by calling me
  • Hashtable (java.util)
    A plug-in replacement for JDK1.5 java.util.Hashtable. This version is based on org.cliffc.high_scale
  • Iterator (java.util)
    An iterator over a sequence of objects, such as a collection.If a collection has been changed since
  • Random (java.util)
    This class provides methods that return pseudo-random values.It is dangerous to seed Random with the
  • ResourceBundle (java.util)
    ResourceBundle is an abstract class which is the superclass of classes which provide Locale-specifi
  • Top PhpStorm plugins
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now