|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.lens.server.metastore.JAXBUtils
public class JAXBUtils
Utilities for converting to and from JAXB types to hive.ql.metadata.cube types
| Field Summary | |
|---|---|
static org.apache.log4j.Logger |
LOG
|
| Constructor Summary | |
|---|---|
JAXBUtils()
|
|
| Method Summary | |
|---|---|
static org.apache.lens.api.metastore.XColumn |
columnFromFieldSchema(org.apache.hadoop.hive.metastore.api.FieldSchema fs)
|
static List<org.apache.lens.api.metastore.XColumn> |
columnsFromFieldSchemaList(List<org.apache.hadoop.hive.metastore.api.FieldSchema> fslist)
|
static CubeDimensionTable |
cubeDimTableFromDimTable(org.apache.lens.api.metastore.XDimensionTable dimensionTable)
|
static CubeFactTable |
cubeFactFromFactTable(org.apache.lens.api.metastore.XFactTable fact)
|
static Dimension |
dimensionFromXDimension(org.apache.lens.api.metastore.XDimension dimension)
|
static List<? extends org.apache.lens.api.metastore.XTableReference> |
dimRefListFromTabRefList(List<TableReference> tabRefs)
|
static org.apache.lens.api.metastore.XDimensionTable |
dimTableFromCubeDimTable(CubeDimensionTable cubeDimTable)
|
static Map<String,UpdatePeriod> |
dumpPeriodsFromStorageTables(org.apache.lens.api.metastore.XStorageTables storageTables)
|
static org.apache.lens.api.metastore.XFactTable |
factTableFromCubeFactTable(CubeFactTable cFact)
|
static org.apache.hadoop.hive.metastore.api.FieldSchema |
fieldSchemaFromColumn(org.apache.lens.api.metastore.XColumn c)
|
static ArrayList<org.apache.hadoop.hive.metastore.api.FieldSchema> |
fieldSchemaListFromColumns(org.apache.lens.api.metastore.XColumns columns)
|
static Date |
getDateFromXML(XMLGregorianCalendar cal)
|
static Map<String,Set<UpdatePeriod>> |
getFactUpdatePeriodsFromStorageTables(org.apache.lens.api.metastore.XStorageTables storageTables)
|
static org.apache.lens.api.metastore.XStorageTableDesc |
getStorageTableDescFromHiveTable(org.apache.hadoop.hive.ql.metadata.Table tbl)
|
static XMLGregorianCalendar |
getXMLGregorianCalendar(Date d)
|
static org.apache.lens.api.metastore.XStorageTableElement |
getXStorageTableFromHiveTable(org.apache.hadoop.hive.ql.metadata.Table tbl)
|
static CubeInterface |
hiveCubeFromXCube(org.apache.lens.api.metastore.XCube cube,
Cube parent)
Create a hive ql cube obejct from corresponding JAXB object |
static CubeDimAttribute |
hiveDimAttrFromXDimAttr(org.apache.lens.api.metastore.XDimAttribute xd)
Create a hive ql CubeDimension from JAXB counterpart |
static ExprColumn |
hiveExprColumnFromXExprColumn(org.apache.lens.api.metastore.XExprColumn xe)
|
static CubeMeasure |
hiveMeasureFromXMeasure(org.apache.lens.api.metastore.XMeasure xm)
Create hive ql CubeMeasure from JAXB counterpart |
static JoinChain |
joinChainFromXJoinChain(org.apache.lens.api.metastore.XJoinChain xj)
Create cube's JoinChain from JAXB counterpart |
static Map<String,String> |
mapFromXProperties(org.apache.lens.api.metastore.XProperties xProperties)
Convert JAXB properties to Map |
static org.apache.lens.api.metastore.XNativeTable |
nativeTableFromMetaTable(org.apache.hadoop.hive.ql.metadata.Table table)
|
static Map<String,String> |
nonTimePartSpecfromXNonTimePartSpec(org.apache.lens.api.metastore.XPartSpec xnonTimePartSpec)
|
static Storage |
storageFromXStorage(org.apache.lens.api.metastore.XStorage xs)
|
static StoragePartitionDesc |
storagePartSpecFromXPartition(org.apache.lens.api.metastore.XPartition xpart)
|
static StorageTableDesc |
storageTableDescFromXStorageTableDesc(org.apache.lens.api.metastore.XStorageTableDesc xtableDesc)
|
static StorageTableDesc |
storageTableDescFromXStorageTableElement(org.apache.lens.api.metastore.XStorageTableElement storageTableElement)
|
static Map<String,StorageTableDesc> |
storageTableMapFromXStorageTables(org.apache.lens.api.metastore.XStorageTables storageTables)
|
static Map<String,Date> |
timePartSpecfromXTimePartSpec(org.apache.lens.api.metastore.XTimePartSpec xtimePartSpec)
|
static org.apache.lens.api.metastore.XCube |
xCubeFromHiveCube(CubeInterface c)
Get XCube from hive.ql.metadata.Cube |
static org.apache.lens.api.metastore.XDimAttribute |
xDimAttrFromHiveDimAttr(CubeDimAttribute cd,
AbstractBaseTable baseTable)
Create XDimAttribute from CubeDimAttribute |
static org.apache.lens.api.metastore.XDimension |
xdimensionFromDimension(Dimension dimension)
|
static org.apache.lens.api.metastore.XExprColumn |
xExprColumnFromHiveExprColumn(ExprColumn ec)
Create XExprColumn from hive ExprColum |
static org.apache.lens.api.metastore.XJoinChain |
XJoinChainFromJoinChain(JoinChain jc)
Create XJoinChain from cube join chain |
static org.apache.lens.api.metastore.XJoinPath |
xJoinPathFromJoinPath(JoinChain.Path path)
|
static org.apache.lens.api.metastore.XMeasure |
xMeasureFromHiveMeasure(CubeMeasure cm)
Create XMeasure from hive ql cube measure |
static org.apache.lens.api.metastore.XPartition |
xpartitionFromPartition(org.apache.hadoop.hive.ql.metadata.Partition p)
|
static List<org.apache.lens.api.metastore.XProperty> |
xPropertiesFromMap(Map<String,String> map)
Convert string map to XProperties |
static org.apache.lens.api.metastore.XStorage |
xstorageFromStorage(Storage storage)
|
static List<org.apache.lens.api.metastore.XTableReference> |
xTabReferencesFromHiveTabReferences(List<TableReference> hiveRefs)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final org.apache.log4j.Logger LOG
| Constructor Detail |
|---|
public JAXBUtils()
| Method Detail |
|---|
public static CubeInterface hiveCubeFromXCube(org.apache.lens.api.metastore.XCube cube,
Cube parent)
throws org.apache.hadoop.hive.ql.parse.ParseException
cube - JAXB Cube
Cube
org.apache.hadoop.hive.ql.parse.ParseExceptionpublic static org.apache.lens.api.metastore.XCube xCubeFromHiveCube(CubeInterface c)
c -
XCubepublic static CubeDimAttribute hiveDimAttrFromXDimAttr(org.apache.lens.api.metastore.XDimAttribute xd)
xd -
CubeDimAttributepublic static XMLGregorianCalendar getXMLGregorianCalendar(Date d)
public static Date getDateFromXML(XMLGregorianCalendar cal)
public static org.apache.lens.api.metastore.XMeasure xMeasureFromHiveMeasure(CubeMeasure cm)
public static org.apache.lens.api.metastore.XExprColumn xExprColumnFromHiveExprColumn(ExprColumn ec)
public static org.apache.lens.api.metastore.XDimAttribute xDimAttrFromHiveDimAttr(CubeDimAttribute cd,
AbstractBaseTable baseTable)
public static org.apache.lens.api.metastore.XJoinChain XJoinChainFromJoinChain(JoinChain jc)
public static org.apache.lens.api.metastore.XJoinPath xJoinPathFromJoinPath(JoinChain.Path path)
public static List<org.apache.lens.api.metastore.XTableReference> xTabReferencesFromHiveTabReferences(List<TableReference> hiveRefs)
public static CubeMeasure hiveMeasureFromXMeasure(org.apache.lens.api.metastore.XMeasure xm)
xm -
CubeMeasurepublic static JoinChain joinChainFromXJoinChain(org.apache.lens.api.metastore.XJoinChain xj)
xj -
JoinChain
public static ExprColumn hiveExprColumnFromXExprColumn(org.apache.lens.api.metastore.XExprColumn xe)
throws org.apache.hadoop.hive.ql.parse.ParseException
org.apache.hadoop.hive.ql.parse.ParseExceptionpublic static Map<String,String> mapFromXProperties(org.apache.lens.api.metastore.XProperties xProperties)
xProperties -
Mappublic static List<org.apache.lens.api.metastore.XProperty> xPropertiesFromMap(Map<String,String> map)
public static org.apache.hadoop.hive.metastore.api.FieldSchema fieldSchemaFromColumn(org.apache.lens.api.metastore.XColumn c)
public static org.apache.lens.api.metastore.XColumn columnFromFieldSchema(org.apache.hadoop.hive.metastore.api.FieldSchema fs)
public static ArrayList<org.apache.hadoop.hive.metastore.api.FieldSchema> fieldSchemaListFromColumns(org.apache.lens.api.metastore.XColumns columns)
public static List<org.apache.lens.api.metastore.XColumn> columnsFromFieldSchemaList(List<org.apache.hadoop.hive.metastore.api.FieldSchema> fslist)
public static Map<String,Set<UpdatePeriod>> getFactUpdatePeriodsFromStorageTables(org.apache.lens.api.metastore.XStorageTables storageTables)
public static Map<String,UpdatePeriod> dumpPeriodsFromStorageTables(org.apache.lens.api.metastore.XStorageTables storageTables)
public static Storage storageFromXStorage(org.apache.lens.api.metastore.XStorage xs)
public static org.apache.lens.api.metastore.XStorage xstorageFromStorage(Storage storage)
public static org.apache.lens.api.metastore.XDimensionTable dimTableFromCubeDimTable(CubeDimensionTable cubeDimTable)
public static List<? extends org.apache.lens.api.metastore.XTableReference> dimRefListFromTabRefList(List<TableReference> tabRefs)
public static CubeDimensionTable cubeDimTableFromDimTable(org.apache.lens.api.metastore.XDimensionTable dimensionTable)
public static CubeFactTable cubeFactFromFactTable(org.apache.lens.api.metastore.XFactTable fact)
public static org.apache.lens.api.metastore.XFactTable factTableFromCubeFactTable(CubeFactTable cFact)
public static StorageTableDesc storageTableDescFromXStorageTableDesc(org.apache.lens.api.metastore.XStorageTableDesc xtableDesc)
public static StorageTableDesc storageTableDescFromXStorageTableElement(org.apache.lens.api.metastore.XStorageTableElement storageTableElement)
public static org.apache.lens.api.metastore.XStorageTableElement getXStorageTableFromHiveTable(org.apache.hadoop.hive.ql.metadata.Table tbl)
public static org.apache.lens.api.metastore.XStorageTableDesc getStorageTableDescFromHiveTable(org.apache.hadoop.hive.ql.metadata.Table tbl)
public static Map<String,StorageTableDesc> storageTableMapFromXStorageTables(org.apache.lens.api.metastore.XStorageTables storageTables)
public static Map<String,Date> timePartSpecfromXTimePartSpec(org.apache.lens.api.metastore.XTimePartSpec xtimePartSpec)
public static Map<String,String> nonTimePartSpecfromXNonTimePartSpec(org.apache.lens.api.metastore.XPartSpec xnonTimePartSpec)
public static org.apache.lens.api.metastore.XPartition xpartitionFromPartition(org.apache.hadoop.hive.ql.metadata.Partition p)
throws org.apache.hadoop.hive.ql.metadata.HiveException
org.apache.hadoop.hive.ql.metadata.HiveExceptionpublic static StoragePartitionDesc storagePartSpecFromXPartition(org.apache.lens.api.metastore.XPartition xpart)
public static Dimension dimensionFromXDimension(org.apache.lens.api.metastore.XDimension dimension)
throws org.apache.hadoop.hive.ql.parse.ParseException
org.apache.hadoop.hive.ql.parse.ParseExceptionpublic static org.apache.lens.api.metastore.XDimension xdimensionFromDimension(Dimension dimension)
public static org.apache.lens.api.metastore.XNativeTable nativeTableFromMetaTable(org.apache.hadoop.hive.ql.metadata.Table table)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||