com.google.cloud.bigtable.hbase.adapters
Class HBaseRequestAdapter
- java.lang.Object
-
- com.google.cloud.bigtable.hbase.adapters.HBaseRequestAdapter
-
public class HBaseRequestAdapter extends Object
Adapts HBase Deletes, Gets, Scans, Puts, RowMutations, Appends and Increments to Bigtable requests.- Version:
- $Id: $Id
- Author:
- sduskis
-
-
Nested Class Summary
Nested Classes Modifier and Type Class and Description static class
HBaseRequestAdapter.MutationAdapters
-
Field Summary
Fields Modifier and Type Field and Description protected BigtableTableName
bigtableTableName
protected HBaseRequestAdapter.MutationAdapters
mutationAdapters
protected TableName
tableName
-
Constructor Summary
Constructors Constructor and Description HBaseRequestAdapter(BigtableOptions options, TableName tableName, org.apache.hadoop.conf.Configuration config)
Constructor for HBaseRequestAdapter.HBaseRequestAdapter(BigtableOptions options, TableName tableName, HBaseRequestAdapter.MutationAdapters mutationAdapters)
Constructor for HBaseRequestAdapter.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description com.google.cloud.bigtable.data.v2.models.ReadModifyWriteRow
adapt(Append append)
adapt.com.google.cloud.bigtable.data.v2.models.RowMutation
adapt(Delete delete)
adapt.void
adapt(Delete delete, com.google.cloud.bigtable.data.v2.models.MutationApi<?> mutationApi)
adapt.com.google.cloud.bigtable.data.v2.models.Query
adapt(Get get)
adapt.com.google.cloud.bigtable.data.v2.models.ReadModifyWriteRow
adapt(Increment increment)
adapt.com.google.cloud.bigtable.data.v2.models.RowMutation
adapt(Mutation mutation)
adapt.com.google.cloud.bigtable.data.v2.models.RowMutation
adapt(Put put)
adapt.void
adapt(Put put, com.google.cloud.bigtable.data.v2.models.MutationApi<?> mutationApi)
adapt.com.google.cloud.bigtable.data.v2.models.RowMutation
adapt(RowMutations mutations)
adapt.void
adapt(RowMutations mutations, com.google.cloud.bigtable.data.v2.models.MutationApi<?> mutationApi)
adapt.com.google.cloud.bigtable.data.v2.models.Query
adapt(Scan scan)
adapt.com.google.cloud.bigtable.data.v2.models.RowMutation
adaptEntry(Delete delete)
adapt.com.google.cloud.bigtable.data.v2.models.RowMutation
adaptEntry(Put put)
adaptEntry.com.google.cloud.bigtable.data.v2.models.RowMutation
adaptEntry(RowMutations mutations)
adaptEntry.BigtableTableName
getBigtableTableName()
Getter for the fieldbigtableTableName
.TableName
getTableName()
Getter for the fieldtableName
.protected String
getTableNameString()
getTableNameString.HBaseRequestAdapter
withServerSideTimestamps()
-
-
-
Field Detail
-
mutationAdapters
protected final HBaseRequestAdapter.MutationAdapters mutationAdapters
-
tableName
protected final TableName tableName
-
bigtableTableName
protected final BigtableTableName bigtableTableName
-
-
Constructor Detail
-
HBaseRequestAdapter
public HBaseRequestAdapter(BigtableOptions options, TableName tableName, org.apache.hadoop.conf.Configuration config)
Constructor for HBaseRequestAdapter.- Parameters:
options
- aBigtableOptions
object.tableName
- aTableName
object.config
- aConfiguration
object.
-
HBaseRequestAdapter
public HBaseRequestAdapter(BigtableOptions options, TableName tableName, HBaseRequestAdapter.MutationAdapters mutationAdapters)
Constructor for HBaseRequestAdapter.- Parameters:
options
- aBigtableOptions
object.tableName
- aTableName
object.mutationAdapters
- aHBaseRequestAdapter.MutationAdapters
object.
-
-
Method Detail
-
withServerSideTimestamps
public HBaseRequestAdapter withServerSideTimestamps()
-
adapt
public com.google.cloud.bigtable.data.v2.models.RowMutation adapt(Delete delete)
adapt.- Parameters:
delete
- aDelete
object.- Returns:
- a
RowMutation
object.
-
adapt
@InternalApi public void adapt(Delete delete, com.google.cloud.bigtable.data.v2.models.MutationApi<?> mutationApi)
adapt.- Parameters:
delete
- aDelete
object.mutationApi
- aMutationApi
object.
-
adaptEntry
public com.google.cloud.bigtable.data.v2.models.RowMutation adaptEntry(Delete delete)
adapt.- Parameters:
delete
- aDelete
object.- Returns:
- a
RowMutation
object.
-
adapt
public com.google.cloud.bigtable.data.v2.models.Query adapt(Get get)
adapt.- Parameters:
get
- aGet
object.- Returns:
- a
Query
object.
-
adapt
public com.google.cloud.bigtable.data.v2.models.Query adapt(Scan scan)
adapt.- Parameters:
scan
- aScan
object.- Returns:
- a
Query
object.
-
adapt
public com.google.cloud.bigtable.data.v2.models.ReadModifyWriteRow adapt(Append append)
adapt.- Parameters:
append
- aAppend
object.- Returns:
- a
ReadModifyWriteRow
object.
-
adapt
public com.google.cloud.bigtable.data.v2.models.ReadModifyWriteRow adapt(Increment increment)
adapt.- Parameters:
increment
- aIncrement
object.- Returns:
- a
ReadModifyWriteRow
object.
-
adapt
public com.google.cloud.bigtable.data.v2.models.RowMutation adapt(Put put)
adapt.- Parameters:
put
- aPut
object.- Returns:
- a
RowMutation
object.
-
adapt
@InternalApi public void adapt(Put put, com.google.cloud.bigtable.data.v2.models.MutationApi<?> mutationApi)
adapt.- Parameters:
put
- aPut
object.mutationApi
- aMutationApi
object.
-
adaptEntry
public com.google.cloud.bigtable.data.v2.models.RowMutation adaptEntry(Put put)
adaptEntry.- Parameters:
put
- aPut
object.- Returns:
- a
RowMutation
object.
-
adapt
public com.google.cloud.bigtable.data.v2.models.RowMutation adapt(RowMutations mutations)
adapt.- Parameters:
mutations
- aRowMutations
object.- Returns:
- a
RowMutation
object.
-
adapt
@InternalApi public void adapt(RowMutations mutations, com.google.cloud.bigtable.data.v2.models.MutationApi<?> mutationApi)
adapt.- Parameters:
mutations
- aRowMutations
object.mutationApi
- aMutationApi
object.
-
adaptEntry
public com.google.cloud.bigtable.data.v2.models.RowMutation adaptEntry(RowMutations mutations)
adaptEntry.- Parameters:
mutations
- aRowMutations
object.- Returns:
- a
RowMutation
object.
-
adapt
public com.google.cloud.bigtable.data.v2.models.RowMutation adapt(Mutation mutation)
adapt.- Parameters:
mutation
- aMutation
object.- Returns:
- a
RowMutation
object.
-
getBigtableTableName
public BigtableTableName getBigtableTableName()
Getter for the fieldbigtableTableName
.- Returns:
- a
BigtableTableName
object.
-
getTableName
public TableName getTableName()
Getter for the fieldtableName
.- Returns:
- a
TableName
object.
-
-