public abstract class PropertyDescriptor extends Object implements org.apache.hadoop.hive.serde2.objectinspector.StructField, ValueSerde, PropertyExtractor
Constructor and Description |
---|
PropertyDescriptor(String name,
ValueSerde serde)
Creates a new instance.
|
PropertyDescriptor(String name,
ValueSerde serde,
String comment)
Creates a new instance.
|
Modifier and Type | Method and Description |
---|---|
abstract ValueOption<?> |
extract(Object dataModel)
Returns the target property in the data model.
|
ValueDriver |
getDriver(org.apache.hadoop.hive.serde2.objectinspector.ObjectInspector target)
Returns an
ValueDriver . |
String |
getFieldComment() |
int |
getFieldID() |
String |
getFieldName() |
org.apache.hadoop.hive.serde2.objectinspector.ObjectInspector |
getFieldObjectInspector() |
org.apache.hadoop.hive.serde2.objectinspector.ObjectInspector |
getInspector()
Returns an
ObjectInspector . |
ColumnInfo |
getSchema()
Returns the
ColumnInfo of this property. |
org.apache.hadoop.hive.serde2.typeinfo.TypeInfo |
getTypeInfo()
Returns the type info.
|
Class<? extends ValueOption<?>> |
getValueClass()
Returns the
ValueOption class. |
String |
toString() |
public PropertyDescriptor(String name, ValueSerde serde)
name
- the property nameserde
- the property accessorpublic PropertyDescriptor(String name, ValueSerde serde, String comment)
name
- the property nameserde
- the property accessorcomment
- comment for the property (nullable)public abstract ValueOption<?> extract(Object dataModel)
PropertyExtractor
extract
in interface PropertyExtractor
dataModel
- the target data modelnull
public org.apache.hadoop.hive.serde2.typeinfo.TypeInfo getTypeInfo()
ValueSerde
getTypeInfo
in interface ValueSerde
public Class<? extends ValueOption<?>> getValueClass()
ValueSerde
ValueOption
class.getValueClass
in interface ValueSerde
ValueOption
classpublic org.apache.hadoop.hive.serde2.objectinspector.ObjectInspector getInspector()
ValueSerde
ObjectInspector
.getInspector
in interface ValueSerde
ObjectInspector
public ValueDriver getDriver(org.apache.hadoop.hive.serde2.objectinspector.ObjectInspector target)
ValueSerde
ValueDriver
.getDriver
in interface ValueSerde
target
- the target ObjectInspector
ValueDriver
for the target ObjectInspector
public String getFieldName()
getFieldName
in interface org.apache.hadoop.hive.serde2.objectinspector.StructField
public org.apache.hadoop.hive.serde2.objectinspector.ObjectInspector getFieldObjectInspector()
getFieldObjectInspector
in interface org.apache.hadoop.hive.serde2.objectinspector.StructField
public String getFieldComment()
getFieldComment
in interface org.apache.hadoop.hive.serde2.objectinspector.StructField
public int getFieldID()
getFieldID
in interface org.apache.hadoop.hive.serde2.objectinspector.StructField
public ColumnInfo getSchema()
ColumnInfo
of this property.ColumnInfo
Copyright © 2011–2019 Asakusa Framework Team. All rights reserved.