public class Convert extends Object
| Constructor and Description |
|---|
Convert() |
| Modifier and Type | Method and Description |
|---|---|
static String |
bytes2String(byte[] bytes)
bytes to string
|
static InputStream |
file2in(String filename,
String prop)
file convert to input stream
|
static org.apache.hadoop.hbase.client.Put |
hdata2put(HData data)
convert hdata to put
|
static Map |
json2Map(net.sf.json.JSONObject json)
json convert to map using ObjectMapper
|
static net.sf.json.JSONObject |
map2Json(Map map)
map convert to json
|
static HData |
result2hdata(org.apache.hadoop.hbase.client.Result result)
convert a result into a hdata
Single row result of a Get or Scan query.
|
public static Map json2Map(net.sf.json.JSONObject json)
json - public static net.sf.json.JSONObject map2Json(Map map)
map - public static InputStream file2in(String filename, String prop) throws Exception
filename - prop - Exceptionpublic static org.apache.hadoop.hbase.client.Put hdata2put(HData data)
data - public static HData result2hdata(org.apache.hadoop.hbase.client.Result result) throws Exception
result - ExceptionCopyright © 2016. All rights reserved.