org.apache.hadoop.hbase.hbql.mapping
Class FieldAttrib

java.lang.Object
  extended by org.apache.hadoop.hbase.hbql.mapping.ColumnAttrib
      extended by org.apache.hadoop.hbase.hbql.mapping.FieldAttrib
All Implemented Interfaces:
Serializable
Direct Known Subclasses:
CurrentValueAnnotationAttrib, ReflectionAttrib, VersionAnnotationAttrib

public abstract class FieldAttrib
extends ColumnAttrib

See Also:
Serialized Form

Constructor Summary
protected FieldAttrib(String familyName, String columnName, Field field, FieldType fieldType, String getter, String setter)
           
 
Method Summary
protected  Class getComponentType()
           
 Object getCurrentValue(Object obj)
           
 Object getDefaultValue()
           
 String getEnclosingClassName()
           
protected  Field getField()
           
protected  Method getMethod(String methodName, Class<?>... params)
           
 String getNameToUseInExceptions()
           
 String getObjectQualifiedName()
           
static String getObjectQualifiedName(Field field)
           
 String getSimpleObjectQualifiedName()
           
 Map<Long,Object> getVersionMap(Object obj)
           
 boolean hasDefaultArg()
           
 void resetDefaultValue()
           
protected static void setAccessible(Field field)
           
 void setCurrentValue(Object obj, long timestamp, Object val)
           
 void setUnMappedCurrentValue(Object obj, String name, byte[] val)
           
 void setUnMappedVersionMap(Object obj, String name, NavigableMap<Long,byte[]> timeStampMap)
           
 String toString()
           
 
Methods inherited from class org.apache.hadoop.hbase.hbql.mapping.ColumnAttrib
defineAccessors, equals, getAliasName, getColumnDefinition, getColumnName, getColumnNameAsBytes, getDefaultArg, getFamilyName, getFamilyNameAsBytes, getFamilyQualifiedName, getFamilyQualifiedNameAsBytes, getFieldType, getGetter, getGetterMethod, getSetter, getSetterMethod, getValueAsBytes, getValueFromBytes, getValueFromBytes, hasAlias, hasGetter, hashCode, hasSetter, invokeGetterMethod, invokeSetterMethod, isACurrentValue, isAKeyAttrib, isAnArray, isASelectFamilyAttrib, isAVersionValue, setCurrentValue, setVersionMap, validateValueWidth
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

FieldAttrib

protected FieldAttrib(String familyName,
                      String columnName,
                      Field field,
                      FieldType fieldType,
                      String getter,
                      String setter)
Method Detail

toString

public String toString()
Overrides:
toString in class Object

getNameToUseInExceptions

public String getNameToUseInExceptions()
Specified by:
getNameToUseInExceptions in class ColumnAttrib

getObjectQualifiedName

public String getObjectQualifiedName()

getSimpleObjectQualifiedName

public String getSimpleObjectQualifiedName()

getObjectQualifiedName

public static String getObjectQualifiedName(Field field)

getEnclosingClassName

public String getEnclosingClassName()
Specified by:
getEnclosingClassName in class ColumnAttrib

getMethod

protected Method getMethod(String methodName,
                           Class<?>... params)
                    throws NoSuchMethodException
Specified by:
getMethod in class ColumnAttrib
Throws:
NoSuchMethodException

getComponentType

protected Class getComponentType()
Specified by:
getComponentType in class ColumnAttrib

getField

protected Field getField()

getCurrentValue

public Object getCurrentValue(Object obj)
                       throws HBqlException
Specified by:
getCurrentValue in class ColumnAttrib
Throws:
HBqlException

setCurrentValue

public void setCurrentValue(Object obj,
                            long timestamp,
                            Object val)
Specified by:
setCurrentValue in class ColumnAttrib

setUnMappedCurrentValue

public void setUnMappedCurrentValue(Object obj,
                                    String name,
                                    byte[] val)
                             throws HBqlException
Specified by:
setUnMappedCurrentValue in class ColumnAttrib
Throws:
HBqlException

setUnMappedVersionMap

public void setUnMappedVersionMap(Object obj,
                                  String name,
                                  NavigableMap<Long,byte[]> timeStampMap)
                           throws HBqlException
Specified by:
setUnMappedVersionMap in class ColumnAttrib
Throws:
HBqlException

getVersionMap

public Map<Long,Object> getVersionMap(Object obj)
                               throws HBqlException
Specified by:
getVersionMap in class ColumnAttrib
Throws:
HBqlException

setAccessible

protected static void setAccessible(Field field)

resetDefaultValue

public void resetDefaultValue()
Overrides:
resetDefaultValue in class ColumnAttrib

getDefaultValue

public Object getDefaultValue()
                       throws HBqlException
Overrides:
getDefaultValue in class ColumnAttrib
Throws:
HBqlException

hasDefaultArg

public boolean hasDefaultArg()
                      throws HBqlException
Overrides:
hasDefaultArg in class ColumnAttrib
Throws:
HBqlException


Copyright © 2011. All Rights Reserved.