org.objectweb.jorm.comp.generator.rdb
Class RdbCommonHelper

java.lang.Object
  |
  +--org.objectweb.jorm.comp.generator.lib.CommonHelper
        |
        +--org.objectweb.jorm.comp.generator.rdb.RdbCommonHelper
All Implemented Interfaces:
Loggable
Direct Known Subclasses:
RdbBindingMOP, RdbMappingMOP

public class RdbCommonHelper
extends CommonHelper

This helper contains all common tool methods shared by the RdbBindingMOP and the RdbMappingMOP.

Author:
Sebastien Chassande-Barrioz

Inner classes inherited from class org.objectweb.jorm.comp.generator.lib.CommonHelper
CommonHelper.PNGDesc
 
Field Summary
protected  RdbAdpater adapter
          This field permits to access to the converstion type.
 
Fields inherited from class org.objectweb.jorm.comp.generator.lib.CommonHelper
logger, loggerFactory, PN_GET_TYPES
 
Constructor Summary
RdbCommonHelper(RdbAdpater adapter)
           
 
Method Summary
 RDBColumnSpec getColumnName(PrimitiveElement pe, CompilerParameter cp)
          This method permits to fetch the column name of the PrimitiveElement specified as parameter.
 java.lang.String getSqlGet(java.lang.String resultSet, PType type, int pos)
           
 
Methods inherited from class org.objectweb.jorm.comp.generator.lib.CommonHelper
canBeNullValue, containsCompositeName, containsCompositeReference, containsGenClassRef, containsReference, containsSerializedField, getCompositeNameDefEntries, getFQNOfCompositeName, getLogger, getLoggerFactory, getPaGetMethod, getPaSetMethod, getPNameDecodeFunction, getPNameEncodeFunction, getPNameGetterGetFunction, getPNGTypes, getPrimitiveElement, getProjectionField, getPType, getPTypeBigDecimal, getPTypeBoolean, getPTypeByte, getPTypeByteArray, getPTypeChar, getPTypeCharArray, getPTypeDate, getPTypeDouble, getPTypeFloat, getPTypeInt, getPTypeLong, getPTypeOboolean, getPTypeObyte, getPTypeOchar, getPTypeOdouble, getPTypeOfloat, getPTypeOint, getPTypeOlong, getPTypeOshort, getPTypeReference, getPTypeSerialized, getPTypeShort, getPTypeString, getSchemaName, isClass, isClassRef, isCompositeName, isFieldName, isGenClassRef, isHiddenField, isPrimitiveElement, isReference, isSerializedField, isSerializedType, isValidString, iterateCompositeName, iterateCompositeReference, setLogger, setLoggerFactory, upperFL
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

adapter

protected RdbAdpater adapter
This field permits to access to the converstion type.
Constructor Detail

RdbCommonHelper

public RdbCommonHelper(RdbAdpater adapter)
Method Detail

getColumnName

public RDBColumnSpec getColumnName(PrimitiveElement pe,
                                   CompilerParameter cp)
                            throws java.lang.Exception
This method permits to fetch the column name of the PrimitiveElement specified as parameter. This method checks that there is only one column because this generator version does not support the mapping of a field on several column.

getSqlGet

public java.lang.String getSqlGet(java.lang.String resultSet,
                                  PType type,
                                  int pos)
                           throws java.lang.Exception