Fully populate this DatabaseMap with all the TablesMaps. This
is only needed if the application needs to use the complete OM
mapping information. Otherwise, the OM Mapping information
will be populated as needed by OM and Peer classes. An example
of how to initialize the map info from the application:
DatabaseMap dbMap = Torque.getDatabaseMap( dbName );
try {
dbMap.initialize();
} catch ( TorqueException e ) {
... error handling
}
Note that Torque database names are case sensitive and this DB
map must be retrieved with the exact name used in the XML schema.
This uses Java reflection methods to locate and run the
init() method of a class generated in the org.apache.torque.linkage
package with a name based on the XML Database name value, e.g.
org.apache.torque.linkage.DefaultMapInit
Some misconfiguration situations that could cause this method to fail
are:
It was used with a Torque OM set of classes generated by V3.2 or older;
The class(es) in the org.apache.torque.linkage package were not included
with the other generated class files (e.g. the jar file creation process
only included com.* and not org.* files).
throws: TorqueException - If an error is encountered locating and callingthe init method. |