|
|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectsf.qof.mapping.AbstractBaseMapping
public abstract class AbstractBaseMapping
| Field Summary | |
|---|---|
protected MappingAdapter |
adapter
|
protected Class<?> |
beanType
|
protected Class<?> |
collectionType
|
protected Constructor<?> |
constructor
|
protected Integer |
constructorParameter
|
protected int |
index
|
protected Class<?> |
mapKeyType
|
protected Method |
method
|
protected String[] |
sqlColumns
|
protected int[] |
sqlIndexes
|
protected Class<?> |
type
|
protected boolean |
usesArray
|
| Constructor Summary | |
|---|---|
AbstractBaseMapping()
|
|
| Method Summary | |
|---|---|
MappingAdapter |
getAdapter()
Returns a custom mapping adapter. |
Class<?> |
getBeanType()
Returns the type of the method parameter Java Bean or null. |
Class<?> |
getCollectionType()
Returns the collection type of the method parameter or null. |
Constructor<?> |
getConstructor()
Returns the constructor or null. |
Integer |
getConstructorParameter()
Returns the index of a parameter in the constructor or null. |
Method |
getGetter()
Returns the getter of the Java Bean or null. |
int |
getIndex()
Returns the method parameter index. |
Class<?> |
getMapKeyType()
Returns the type of the method return map key or null. |
Method |
getSetter()
Returns the setter of the Java Bean or null. |
String[] |
getSqlColumns()
Returns an array with the column names in the SQL statement. |
int[] |
getSqlIndexes()
Returns an array with the indexes in the SQL statement. |
Class<?> |
getType()
Returns mapping type. |
boolean |
isMapKey()
True if mapping is a key for a Map. |
String |
parameterMappingInfo()
Return info for parameter mapping. |
String |
resultMappingInfo()
Return info for result mapping. |
void |
setParameters(Class<?> type,
Class<?> collectionType,
Class<?> beanType,
Method setter,
int[] sqlIndexes,
String[] sqlColumns,
MappingAdapter adapter,
Class<?> mapKeyType,
Integer constructorParameter,
Constructor<?> constructor)
Initializer. |
void |
setParameters(int index,
Class<?> type,
Class<?> collectionType,
Class<?> beanType,
Method getter,
int[] sqlIndexes,
String[] sqlColumns,
MappingAdapter adapter,
boolean usesArray)
Initializer. |
boolean |
usesArray()
True if the parameter is an array. |
boolean |
usesAtomic()
True if the method parameter is either a primitive or an atomic value (like String). |
boolean |
usesCollection()
True if the method parameter is a collection type. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface sf.qof.mapping.Mapping |
|---|
accept |
| Field Detail |
|---|
protected int[] sqlIndexes
protected String[] sqlColumns
protected int index
protected Class<?> type
protected Class<?> collectionType
protected Class<?> mapKeyType
protected Class<?> beanType
protected Method method
protected MappingAdapter adapter
protected Integer constructorParameter
protected Constructor<?> constructor
protected boolean usesArray
| Constructor Detail |
|---|
public AbstractBaseMapping()
| Method Detail |
|---|
public void setParameters(int index,
Class<?> type,
Class<?> collectionType,
Class<?> beanType,
Method getter,
int[] sqlIndexes,
String[] sqlColumns,
MappingAdapter adapter,
boolean usesArray)
ParameterMapping
setParameters in interface ParameterMappingindex - method parameter indextype - mapping typecollectionType - collection type of method parameterbeanType - Java Bean object type of method parametergetter - getter form Java Bean objectsqlIndexes - array of SQL indexessqlColumns - array of SQL column namesadapter - custom mapping adapterusesArray - parameter is an array
public void setParameters(Class<?> type,
Class<?> collectionType,
Class<?> beanType,
Method setter,
int[] sqlIndexes,
String[] sqlColumns,
MappingAdapter adapter,
Class<?> mapKeyType,
Integer constructorParameter,
Constructor<?> constructor)
ResultMapping
setParameters in interface ResultMappingtype - mapping typecollectionType - collection type of method return resultbeanType - Java Bean object type of method return resultsetter - setter form Java Bean objectsqlIndexes - array of SQL indexessqlColumns - array of SQL column namesadapter - custom mapping adaptermapKeyType - map key typeconstructorParameter - index of a parameter in the constructorconstructor - constructorpublic Class<?> getBeanType()
ParameterMapping
getBeanType in interface ParameterMappinggetBeanType in interface ResultMappingpublic Class<?> getCollectionType()
ParameterMappingCollection.
getCollectionType in interface ParameterMappinggetCollectionType in interface ResultMappingpublic int getIndex()
ParameterMapping
getIndex in interface ParameterMappingpublic Method getGetter()
ParameterMapping
getGetter in interface ParameterMappingpublic Method getSetter()
ResultMapping
getSetter in interface ResultMappingpublic String[] getSqlColumns()
ParameterMapping
getSqlColumns in interface ParameterMappinggetSqlColumns in interface ResultMappingpublic int[] getSqlIndexes()
ParameterMapping
getSqlIndexes in interface ParameterMappinggetSqlIndexes in interface ResultMappingpublic Class<?> getType()
ParameterMapping
getType in interface ParameterMappinggetType in interface ResultMappingpublic MappingAdapter getAdapter()
ParameterMapping
getAdapter in interface ParameterMappinggetAdapter in interface ResultMappingpublic boolean usesCollection()
ParameterMapping
usesCollection in interface ParameterMappingusesCollection in interface ResultMappingpublic boolean usesAtomic()
ParameterMappingString).
usesAtomic in interface ParameterMappingusesAtomic in interface ResultMappingpublic boolean isMapKey()
ResultMappingMap.
isMapKey in interface ResultMappingpublic Class<?> getMapKeyType()
ResultMapping
getMapKeyType in interface ResultMappingpublic Integer getConstructorParameter()
ResultMapping
getConstructorParameter in interface ResultMappingpublic Constructor<?> getConstructor()
ResultMapping
getConstructor in interface ResultMappingpublic boolean usesArray()
ParameterMapping
usesArray in interface ParameterMappingpublic String parameterMappingInfo()
Mapping
parameterMappingInfo in interface Mappingpublic String resultMappingInfo()
Mapping
resultMappingInfo in interface Mapping
|
|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||