Author: tfischer
Date: Sun Jan  9 10:28:32 2011
New Revision: 1056906

URL: http://svn.apache.org/viewvc?rev=1056906&view=rev
Log:
Added documentation on how to create a custom platform

Modified:
    
db/torque/torque4/trunk/torque-site/src/site/xdoc/documentation/modules/templates/customizing.xml

Modified: 
db/torque/torque4/trunk/torque-site/src/site/xdoc/documentation/modules/templates/customizing.xml
URL: 
http://svn.apache.org/viewvc/db/torque/torque4/trunk/torque-site/src/site/xdoc/documentation/modules/templates/customizing.xml?rev=1056906&r1=1056905&r2=1056906&view=diff
==============================================================================
--- 
db/torque/torque4/trunk/torque-site/src/site/xdoc/documentation/modules/templates/customizing.xml
 (original)
+++ 
db/torque/torque4/trunk/torque-site/src/site/xdoc/documentation/modules/templates/customizing.xml
 Sun Jan  9 10:28:32 2011
@@ -392,6 +392,20 @@
     </table>
   </section>
 
+  <section name="Altering the SQL type mapping">
+    If you want to alter the way the Torque data types are mapped to SQL types
+    or generate SQL for a dtadabase type not supported by Torque,
+    you can write a custom platform class. This class must implement the
+    <code>Platform</code> interface in the package 
+    <code>org.apache.torque.templates.platform</code>.
+    The class itself must be in the same 
+    <code>org.apache.torque.templates.platform</code> package and 
+    its name must be Platform${CustomName}Impl.
+    Then, put the class file in the class path from where it
+    can be accessed by the templates, and set the option
+    <code>torque.database</code> to ${customName}.
+  </section>
+
   <section name="Overriding templates">
     If there is no option which does what you want, you can override
     some of the templates. See the generator reference and the ant tasks



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to