org.objectweb.speedo.generation.jorm
Interface JormMIMappingBuilder

All Known Implementing Classes:
RdbJORMMapping

public interface JormMIMappingBuilder

This interface defines a builder of the mapping part of the Jorm meta information. It must be implemented for each mapper.

Author:
S.Chassande-Barrioz

Method Summary
 void createClassIdentifierNameDefMapping(org.objectweb.jorm.metainfo.api.ClassMapping cm, org.objectweb.jorm.metainfo.api.NameDef nd, SpeedoClass sc, MIBuilderHelper mibh)
          Creates the mapping of the name def (JORM meta object) corresponding to the identifier of a persistent generic class (collection, map, ...).
 org.objectweb.jorm.metainfo.api.ClassMapping createClassMapping(org.objectweb.jorm.metainfo.api.Class clazz, SpeedoClass sc, org.objectweb.jorm.metainfo.api.Mapping mapping)
          It builds a ClassMapping, assignes it to the mapping and builds mapping structure for the class (RdbTable, directory name, ...).
 void createClassRefNameDefMapping(org.objectweb.jorm.metainfo.api.ClassMapping cm, org.objectweb.jorm.metainfo.api.NameDef nd, SpeedoCommonField sf)
          Creates the mapping of the name def (JORM meta object) corresponding to a reference to a persistent class from a persistent class.
 void createClassRefNameDefMapping(org.objectweb.jorm.metainfo.api.GenClassMapping gcm, org.objectweb.jorm.metainfo.api.NameDef nd, SpeedoField sf)
          Creates the mapping of the name def (JORM meta object) corresponding to a reference to a persistent class from a generic persistent class.
 org.objectweb.jorm.metainfo.api.PrimitiveElementMapping createFieldMapping(org.objectweb.jorm.metainfo.api.PrimitiveElement pe, SpeedoField sf, org.objectweb.jorm.metainfo.api.ClassMapping cm)
          It creates the mapping of a primitive field.
 org.objectweb.jorm.metainfo.api.PrimitiveElementMapping createFieldMapping(org.objectweb.jorm.metainfo.api.PrimitiveElement pe, SpeedoInheritedField sif, org.objectweb.jorm.metainfo.api.ClassMapping cm)
          /** It creates the mapping of an inherited primitive field.
 org.objectweb.jorm.metainfo.api.PrimitiveElementMapping createFieldMapping(org.objectweb.jorm.metainfo.api.PrimitiveElement pe, SpeedoNoFieldColumn sf, org.objectweb.jorm.metainfo.api.ClassMapping cm)
          It creates the mapping of a hidden primitive field.
 org.objectweb.jorm.metainfo.api.PrimitiveElementMapping createGenClassElementMapping(org.objectweb.jorm.metainfo.api.PrimitiveElement pe, SpeedoField sf, org.objectweb.jorm.metainfo.api.GenClassMapping gcm)
          It creates the mapping of a primitive field (element of the generic class).
 void createGenClassIdentifierNameDefMapping(org.objectweb.jorm.metainfo.api.GenClassMapping gcm, org.objectweb.jorm.metainfo.api.NameDef nd, SpeedoField sf, MIBuilderHelper mibh)
          Creates the mapping of the name def (JORM meta object) corresponding to the identifier of a persistent generic class (collection, map, ...).
 org.objectweb.jorm.metainfo.api.PrimitiveElementMapping createGenClassIndexMapping(org.objectweb.jorm.metainfo.api.PrimitiveElement pe, SpeedoField sf, org.objectweb.jorm.metainfo.api.GenClassMapping gcm)
          It creates the mapping of a primitive field used as index in the generic class.
 org.objectweb.jorm.metainfo.api.GenClassMapping createGenClassMapping(org.objectweb.jorm.metainfo.api.GenClassRef gcr, SpeedoField sf, org.objectweb.jorm.metainfo.api.Mapping mapping)
          It builds a GenClassMapping, assignes it to the mapping and builds mapping structure for the class (RdbTable, directory name, ...).
 void createGenClassRefNameDefMapping(org.objectweb.jorm.metainfo.api.ClassMapping cm, org.objectweb.jorm.metainfo.api.NameDef nd, SpeedoCommonField sf)
          Creates the mapping of the name def (JORM meta object) corresponding to a reference to a persistent generic class.
 

Method Detail

createClassMapping

org.objectweb.jorm.metainfo.api.ClassMapping createClassMapping(org.objectweb.jorm.metainfo.api.Class clazz,
                                                                SpeedoClass sc,
                                                                org.objectweb.jorm.metainfo.api.Mapping mapping)
                                                                throws org.objectweb.jorm.api.PException,
                                                                       SpeedoException
It builds a ClassMapping, assignes it to the mapping and builds mapping structure for the class (RdbTable, directory name, ...).

Parameters:
clazz - is the Jorm meta object representing the class which the ClassMapping must be built.
mapping - is the Mapping instance which will host the ClassMapping.
Returns:
the ClassMapping instance built by the method (never null).
Throws:
org.objectweb.jorm.api.PException - if it is not possible to build the ClassMapping
SpeedoException

createGenClassMapping

org.objectweb.jorm.metainfo.api.GenClassMapping createGenClassMapping(org.objectweb.jorm.metainfo.api.GenClassRef gcr,
                                                                      SpeedoField sf,
                                                                      org.objectweb.jorm.metainfo.api.Mapping mapping)
                                                                      throws org.objectweb.jorm.api.PException,
                                                                             SpeedoException
It builds a GenClassMapping, assignes it to the mapping and builds mapping structure for the class (RdbTable, directory name, ...).

Parameters:
gcr - is the Jorm meta object representing the gen class which the GenClassMapping must be built.
mapping - is the Mapping instance which will host the GenClassMapping.
sf - is the SpeedoField corresponding to the generic class.
Returns:
the GenClassMapping instance built by the method (never null).
Throws:
org.objectweb.jorm.api.PException - if it is not possible to build the GenClassMapping
SpeedoException

createFieldMapping

org.objectweb.jorm.metainfo.api.PrimitiveElementMapping createFieldMapping(org.objectweb.jorm.metainfo.api.PrimitiveElement pe,
                                                                           SpeedoField sf,
                                                                           org.objectweb.jorm.metainfo.api.ClassMapping cm)
                                                                           throws org.objectweb.jorm.api.PException,
                                                                                  SpeedoException
It creates the mapping of a primitive field.

Parameters:
pe - is the Jorm meta object representing a primitive field
cm - is the MappingStructure which will host the mapping of the field
Returns:
a PrimitiveElementMapping corresponding to the given primitive field.
Throws:
org.objectweb.jorm.api.PException - if it is not possible to build the mapping of the primitive field.
SpeedoException

createFieldMapping

org.objectweb.jorm.metainfo.api.PrimitiveElementMapping createFieldMapping(org.objectweb.jorm.metainfo.api.PrimitiveElement pe,
                                                                           SpeedoNoFieldColumn sf,
                                                                           org.objectweb.jorm.metainfo.api.ClassMapping cm)
                                                                           throws org.objectweb.jorm.api.PException,
                                                                                  SpeedoException
It creates the mapping of a hidden primitive field.

Parameters:
pe - is the Jorm meta object representing a primitive field
cm - is the MappingStructure which will host the mapping of the field
Returns:
a PrimitiveElementMapping corresponding to the given primitive field.
Throws:
org.objectweb.jorm.api.PException - if it is not possible to build the mapping of the primitive field.
SpeedoException

createFieldMapping

org.objectweb.jorm.metainfo.api.PrimitiveElementMapping createFieldMapping(org.objectweb.jorm.metainfo.api.PrimitiveElement pe,
                                                                           SpeedoInheritedField sif,
                                                                           org.objectweb.jorm.metainfo.api.ClassMapping cm)
                                                                           throws org.objectweb.jorm.api.PException,
                                                                                  SpeedoException
/** It creates the mapping of an inherited primitive field.

Parameters:
pe - is the Jorm meta object representing a primitive field
sif - is the SpeedoInheritedField meta object representing the inherited field.
cm - is the MappingStructure which will host the mapping of the field
Returns:
a PrimitiveElementMapping corresponding to the given primitive field.
Throws:
org.objectweb.jorm.api.PException
SpeedoException

createGenClassElementMapping

org.objectweb.jorm.metainfo.api.PrimitiveElementMapping createGenClassElementMapping(org.objectweb.jorm.metainfo.api.PrimitiveElement pe,
                                                                                     SpeedoField sf,
                                                                                     org.objectweb.jorm.metainfo.api.GenClassMapping gcm)
                                                                                     throws org.objectweb.jorm.api.PException,
                                                                                            SpeedoException
It creates the mapping of a primitive field (element of the generic class).

Parameters:
pe - is the Jorm meta object representing a primitive field
gcm - is the MappingStructure which will host the mapping of the field
sf - is the Speedo meta object representing the persistent field referencing a generic class.
Returns:
a PrimitiveElementMapping corresponding to the given primitive field.
Throws:
org.objectweb.jorm.api.PException - if it is not possible to build the mapping of the primitive field.
SpeedoException

createGenClassIndexMapping

org.objectweb.jorm.metainfo.api.PrimitiveElementMapping createGenClassIndexMapping(org.objectweb.jorm.metainfo.api.PrimitiveElement pe,
                                                                                   SpeedoField sf,
                                                                                   org.objectweb.jorm.metainfo.api.GenClassMapping gcm)
                                                                                   throws org.objectweb.jorm.api.PException,
                                                                                          SpeedoException
It creates the mapping of a primitive field used as index in the generic class.

Parameters:
pe - is the Jorm meta object representing a primitive field
gcm - is the MappingStructure which will host the mapping of the field
sf - is the Speedo meta object representing the persistent field referencing a generic class.
Returns:
a PrimitiveElementMapping corresponding to the given primitive field.
Throws:
org.objectweb.jorm.api.PException - if it is not possible to build the mapping of the primitive field.
SpeedoException

createClassIdentifierNameDefMapping

void createClassIdentifierNameDefMapping(org.objectweb.jorm.metainfo.api.ClassMapping cm,
                                         org.objectweb.jorm.metainfo.api.NameDef nd,
                                         SpeedoClass sc,
                                         MIBuilderHelper mibh)
                                         throws org.objectweb.jorm.api.PException,
                                                SpeedoException
Creates the mapping of the name def (JORM meta object) corresponding to the identifier of a persistent generic class (collection, map, ...).

Parameters:
cm - is the MappingStructure which will host the mapping of the generic class
nd - is the namedef corresponding to the identifier of the generic class
sc - is the Speedo meta object representing the persistent class.
Throws:
org.objectweb.jorm.api.PException
SpeedoException

createGenClassIdentifierNameDefMapping

void createGenClassIdentifierNameDefMapping(org.objectweb.jorm.metainfo.api.GenClassMapping gcm,
                                            org.objectweb.jorm.metainfo.api.NameDef nd,
                                            SpeedoField sf,
                                            MIBuilderHelper mibh)
                                            throws org.objectweb.jorm.api.PException,
                                                   SpeedoException
Creates the mapping of the name def (JORM meta object) corresponding to the identifier of a persistent generic class (collection, map, ...).

Parameters:
gcm - is the MappingStructure which will host the mapping of the generic class
nd - is the namedef corresponding to the identifier of the generic class
sf - is the Speedo meta object representing the persistent field referencing a generic class.
Throws:
org.objectweb.jorm.api.PException
SpeedoException

createClassRefNameDefMapping

void createClassRefNameDefMapping(org.objectweb.jorm.metainfo.api.ClassMapping cm,
                                  org.objectweb.jorm.metainfo.api.NameDef nd,
                                  SpeedoCommonField sf)
                                  throws org.objectweb.jorm.api.PException,
                                         SpeedoException
Creates the mapping of the name def (JORM meta object) corresponding to a reference to a persistent class from a persistent class.

Parameters:
cm - is the MappingStructure which will host the mapping of the reference
nd - is the namedef corresponding to the reference
sf - is the Speedo meta object representing the persistent field referencing a class.
Throws:
org.objectweb.jorm.api.PException
SpeedoException

createClassRefNameDefMapping

void createClassRefNameDefMapping(org.objectweb.jorm.metainfo.api.GenClassMapping gcm,
                                  org.objectweb.jorm.metainfo.api.NameDef nd,
                                  SpeedoField sf)
                                  throws org.objectweb.jorm.api.PException,
                                         SpeedoException
Creates the mapping of the name def (JORM meta object) corresponding to a reference to a persistent class from a generic persistent class.

Parameters:
gcm - is the MappingStructure which will host the mapping of the reference
nd - is the namedef corresponding to the reference
sf - is the Speedo meta object representing the persistent field referencing a generic class.
Throws:
org.objectweb.jorm.api.PException
SpeedoException

createGenClassRefNameDefMapping

void createGenClassRefNameDefMapping(org.objectweb.jorm.metainfo.api.ClassMapping cm,
                                     org.objectweb.jorm.metainfo.api.NameDef nd,
                                     SpeedoCommonField sf)
                                     throws org.objectweb.jorm.api.PException,
                                            SpeedoException
Creates the mapping of the name def (JORM meta object) corresponding to a reference to a persistent generic class.

Parameters:
cm - is the MappingStructure which will host the mapping of the reference
nd - is the namedef corresponding to the reference
sf - is the Speedo meta object representing the persistent field referencing a generic class.
Throws:
org.objectweb.jorm.api.PException
SpeedoException