@InterfaceAudience.Private public class ThriftUtilities extends Object
| Constructor and Description |
|---|
ThriftUtilities() |
| Modifier and Type | Method and Description |
|---|---|
static List<TCell> |
cellFromHBase(Cell in)
This utility method creates a list of Thrift TCell "struct" based on
an Hbase Cell object.
|
static List<TCell> |
cellFromHBase(Cell[] in)
This utility method creates a list of Thrift TCell "struct" based on
an Hbase Cell array.
|
static ColumnDescriptor |
colDescFromHbase(HColumnDescriptor in)
This utility method creates a new Thrift ColumnDescriptor "struct" based on
an Hbase HColumnDescriptor object.
|
static HColumnDescriptor |
colDescFromThrift(ColumnDescriptor in)
This utility method creates a new Hbase HColumnDescriptor object based on a
Thrift ColumnDescriptor "struct".
|
static Increment |
incrementFromThrift(TIncrement tincrement)
From a
TIncrement create an Increment. |
static List<TRowResult> |
rowResultFromHBase(Result in) |
static List<TRowResult> |
rowResultFromHBase(Result[] in)
This utility method creates a list of Thrift TRowResult "struct" based on
an array of Hbase RowResult objects.
|
static List<TRowResult> |
rowResultFromHBase(Result[] in,
boolean sortColumns)
This utility method creates a list of Thrift TRowResult "struct" based on
an Hbase RowResult object.
|
public static HColumnDescriptor colDescFromThrift(ColumnDescriptor in) throws IllegalArgument
in - Thrift ColumnDescriptor objectIllegalArgumentpublic static ColumnDescriptor colDescFromHbase(HColumnDescriptor in)
in - Hbase HColumnDescriptor objectpublic static List<TCell> cellFromHBase(Cell in)
in - Hbase Cell objectpublic static List<TCell> cellFromHBase(Cell[] in)
in - Hbase Cell arraypublic static List<TRowResult> rowResultFromHBase(Result[] in, boolean sortColumns)
in - Hbase RowResult objectsortColumns - This boolean dictates if row data is returned in a sorted order
sortColumns = True will set TRowResult's sortedColumns member
which is an ArrayList of TColumn struct
sortColumns = False will set TRowResult's columns member which is
a map of columnName and TCell structpublic static List<TRowResult> rowResultFromHBase(Result[] in)
in - Array of Hbase RowResult objectspublic static List<TRowResult> rowResultFromHBase(Result in)
public static Increment incrementFromThrift(TIncrement tincrement)
TIncrement create an Increment.tincrement - the Thrift version of an incrementTIncrement represented.Copyright © 2014 The Apache Software Foundation. All rights reserved.