|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.exolab.castor.mapping.loader.AbstractMappingLoader2
org.exolab.castor.mapping.loader.AbstractMappingLoader
org.exolab.castor.jdo.engine.JDOMappingLoader
public final class JDOMappingLoader
A JDO implementation of mapping helper. Creates JDO class descriptors from the mapping file.
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from class org.exolab.castor.mapping.loader.AbstractMappingLoader |
|---|
AbstractMappingLoader.TypeInfoReference |
| Field Summary |
|---|
| Fields inherited from class org.exolab.castor.mapping.loader.AbstractMappingLoader |
|---|
EMPTY_ARGS, STRING_ARG, VALUE_OF |
| Constructor Summary | |
|---|---|
JDOMappingLoader(ClassLoader loader)
Creates an instance of JDOMappingLoader, providing a
ClassLoader instance. |
|
| Method Summary | |
|---|---|
protected ClassDescriptor |
createClassDescriptor(ClassMapping classMapping)
|
protected FieldDescriptorImpl |
createFieldDesc(Class javaClass,
FieldMapping fieldMap)
|
static String |
definition2param(String sqlTypeDef)
Extracts parameter for type convertor from the SQL type definition of the form "SQL_TYPE_NAME[PARAMETER]". |
static String |
definition2type(String sqlTypeDef)
Extracts SQL type name from the the SQL type definition of the form "SQL_TYPE_NAME[PARAMETER]". |
protected FieldDescriptor |
findIdentityByName(List<FieldDescriptor> fldList,
String idName,
Class javaClass)
|
BindingType |
getBindingType()
|
protected String[] |
getSqlTypes(FieldMapping fieldMap)
Parse the sql type attribute to build an array of types, needed to support whitespace inside parameterized types (see Bug 1045). |
protected TypeInfo |
getTypeInfo(Class fieldType,
CollectionHandler colHandler,
FieldMapping fieldMap)
|
void |
loadMapping(MappingRoot mapping,
Object param)
|
protected void |
resolveRelations(ClassDescriptor clsDesc)
Walks through all fields of a descriptor and resolves relation ClassDescriptors by using mapping information or, if not
present, resolution by file to support generated
ClassDescriptors. |
| Methods inherited from class org.exolab.castor.mapping.loader.AbstractMappingLoader |
|---|
checkFieldNameDuplicates, createClassDescriptors, createFieldDescriptors, createFieldHandler, createFieldHandlers, divideFieldDescriptors, findAccessor, getDepended, getExtended, getIdColumnIndex, getIdentityColumnNames, getInternalContext, getOrigin, getSourceType, isPrimitive, resolveType, setInternalContext |
| Methods inherited from class org.exolab.castor.mapping.loader.AbstractMappingLoader2 |
|---|
addDescriptor, clear, descriptorIterator, getClassLoader, getDescriptor, getDescriptors, isAllowRedefinition, loadMapping, setAllowRedefinitions, setClassLoader |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public JDOMappingLoader(ClassLoader loader)
JDOMappingLoader, providing a
ClassLoader instance.
loader - A Custom ClassLoader instance.| Method Detail |
|---|
public static String definition2param(String sqlTypeDef)
sqlTypeDef - SQL type definition (e.g. char[01]).
public static String definition2type(String sqlTypeDef)
sqlTypeDef - SQL type definition (e.g. char[01]).
public BindingType getBindingType()
public void loadMapping(MappingRoot mapping,
Object param)
throws MappingException
loadMapping in class AbstractMappingLoaderMappingException
protected ClassDescriptor createClassDescriptor(ClassMapping classMapping)
throws MappingException
createClassDescriptor in class AbstractMappingLoaderMappingException
protected FieldDescriptor findIdentityByName(List<FieldDescriptor> fldList,
String idName,
Class javaClass)
throws MappingException
MappingExceptionprotected void resolveRelations(ClassDescriptor clsDesc)
ClassDescriptors by using mapping information or, if not
present, resolution by file to support generated
ClassDescriptors. Resolved ClassDescriptors will be
set as a field's descriptor.
resolveRelations in class AbstractMappingLoaderclsDesc - The ClassDescriptor in focus.protected String[] getSqlTypes(FieldMapping fieldMap)
protected TypeInfo getTypeInfo(Class fieldType,
CollectionHandler colHandler,
FieldMapping fieldMap)
throws MappingException
getTypeInfo in class AbstractMappingLoaderMappingException
protected FieldDescriptorImpl createFieldDesc(Class javaClass,
FieldMapping fieldMap)
throws MappingException
createFieldDesc in class AbstractMappingLoaderMappingException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||