public class ThriftUtilities extends Object
Modifier and Type | Method and Description |
---|---|
static Append |
appendFromThrift(TAppend append) |
static TDelete |
deleteFromHBase(Delete in) |
static Delete |
deleteFromThrift(TDelete in)
Creates a
Delete (HBase) from a TDelete (Thrift). |
static List<Delete> |
deletesFromThrift(List<TDelete> in)
Converts multiple
TDelete s (Thrift) into a list of Delete s (HBase). |
static Get |
getFromThrift(TGet in)
Creates a
Get (HBase) from a TGet (Thrift). |
static List<Get> |
getsFromThrift(List<TGet> in)
Converts multiple
TGet s (Thrift) into a list of Get s (HBase). |
static Increment |
incrementFromThrift(TIncrement in) |
static Put |
putFromThrift(TPut in)
Creates a
Put (HBase) from a TPut (Thrift) |
static List<Put> |
putsFromThrift(List<TPut> in)
Converts multiple
TPut s (Thrift) into a list of Put s (HBase). |
static THRegionLocation |
regionLocationFromHBase(HRegionLocation hrl) |
static List<THRegionLocation> |
regionLocationsFromHBase(List<HRegionLocation> locations) |
static TResult |
resultFromHBase(Result in)
Creates a
TResult (Thrift) from a Result (HBase). |
static List<TResult> |
resultsFromHBase(Result[] in)
Converts multiple
Result s (HBase) into a list of TResult s (Thrift). |
static RowMutations |
rowMutationsFromThrift(TRowMutations in)
Creates a
RowMutations (HBase) from a TRowMutations (Thrift) |
static Scan |
scanFromThrift(TScan in) |
public static Get getFromThrift(TGet in) throws IOException
in
- the TGet
to convertGet
objectIOException
- if an invalid time range or max version parameter is givenpublic static List<Get> getsFromThrift(List<TGet> in) throws IOException
TGet
s (Thrift) into a list of Get
s (HBase).in
- list of TGet
s to convertGet
objectsIOException
- if an invalid time range or max version parameter is givengetFromThrift(TGet)
public static TResult resultFromHBase(Result in)
TResult
(Thrift) from a Result
(HBase).in
- the Result
to convertnull
public static List<TResult> resultsFromHBase(Result[] in)
Result
s (HBase) into a list of TResult
s (Thrift).in
- array of Result
s to convertTResult
sresultFromHBase(Result)
public static Put putFromThrift(TPut in)
Put
(HBase) from a TPut
(Thrift)in
- the TPut
to convertPut
public static List<Put> putsFromThrift(List<TPut> in)
TPut
s (Thrift) into a list of Put
s (HBase).in
- list of TPut
s to convertPut
sputFromThrift(TPut)
public static Delete deleteFromThrift(TDelete in)
Delete
(HBase) from a TDelete
(Thrift).in
- the TDelete
to convertDelete
public static List<Delete> deletesFromThrift(List<TDelete> in)
TDelete
s (Thrift) into a list of Delete
s (HBase).in
- list of TDelete
s to convertDelete
sdeleteFromThrift(TDelete)
public static TDelete deleteFromHBase(Delete in)
public static RowMutations rowMutationsFromThrift(TRowMutations in) throws IOException
RowMutations
(HBase) from a TRowMutations
(Thrift)in
- the TRowMutations
to convertRowMutations
IOException
public static Scan scanFromThrift(TScan in) throws IOException
IOException
public static Increment incrementFromThrift(TIncrement in) throws IOException
IOException
public static Append appendFromThrift(TAppend append) throws IOException
IOException
public static THRegionLocation regionLocationFromHBase(HRegionLocation hrl)
public static List<THRegionLocation> regionLocationsFromHBase(List<HRegionLocation> locations)