Fixed class names of references to tools

git-svn-id: https://svn.apache.org/repos/asf/incubator/openjpa/trunk@446900 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Marc Prud'hommeaux 2006-09-16 17:22:29 +00:00
parent 0c34969609
commit d746a3fd7c
7 changed files with 46 additions and 53 deletions

View File

@ -168,10 +168,11 @@ files listed above.
<para> <para>
<indexterm> <indexterm>
<primary> <primary>
openjpac org.apache.openjpa.enhance.PCEnhancer
</primary> </primary>
</indexterm> </indexterm>
<command>openjpac</command>: Runs the OpenJPA enhancer against the specified <command>org.apache.openjpa.enhance.PCEnhancer</command>:
Runs the OpenJPA enhancer against the specified
classes. More information is available in <xref linkend="ref_guide_pc_enhance"/> classes. More information is available in <xref linkend="ref_guide_pc_enhance"/>
of the Reference Guide. of the Reference Guide.
</para> </para>
@ -180,10 +181,11 @@ classes. More information is available in <xref linkend="ref_guide_pc_enhance"/>
<para> <para>
<indexterm> <indexterm>
<primary> <primary>
mappingtool org.apache.openjpa.jdbc.meta.MappingTool
</primary> </primary>
</indexterm> </indexterm>
<command>mappingtool</command>: A utility that can be used to create and <command>org.apache.openjpa.jdbc.meta.MappingTool</command>:
A utility that can be used to create and
maintain the object-relational mappings and schema of all persistent classes in maintain the object-relational mappings and schema of all persistent classes in
a JDBC-compliant datastore. This functionality allows the underlying mappings a JDBC-compliant datastore. This functionality allows the underlying mappings
and schema to be easily kept up-to-date with the Java classes in the system. See and schema to be easily kept up-to-date with the Java classes in the system. See
@ -369,7 +371,7 @@ You can use any java compiler instead of <command>javac</command>.
Enhance the persistent classes. Enhance the persistent classes.
</para> </para>
<programlisting> <programlisting>
openjpac -p persistence.xml Animal.java Dog.java java org.apache.openjpa.enhance.PCEnhancer -p persistence.xml Animal.java Dog.java
</programlisting> </programlisting>
<para> <para>
This step runs the OpenJPA enhancer on the <filename>Animal.java</filename> and This step runs the OpenJPA enhancer on the <filename>Animal.java</filename> and
@ -413,13 +415,13 @@ the Reference Guide.
<para> <para>
<indexterm> <indexterm>
<primary> <primary>
mappingtool org.apache.openjpa.jdbc.meta.MappingTool
</primary> </primary>
</indexterm> </indexterm>
Create the object-relational mappings and database schema. Create the object-relational mappings and database schema.
</para> </para>
<programlisting> <programlisting>
mappingtool -p persistence.xml Animal.java Dog.java java org.apache.openjpa.jdbc.meta.MappingTool -p persistence.xml Animal.java Dog.java
</programlisting> </programlisting>
<para> <para>
This command propagates the necessary schema for the specified classes to the This command propagates the necessary schema for the specified classes to the
@ -443,7 +445,7 @@ If you are curious, you can view the schema OpenJPA created for the tutorial
classes with OpenJPA's schema tool: classes with OpenJPA's schema tool:
</para> </para>
<programlisting> <programlisting>
schematool -p persistence.xml -a reflect -f tmp.schema java org.apache.openjpa.jdbc.schema.SchemaTool -p persistence.xml -a reflect -f tmp.schema
</programlisting> </programlisting>
<para> <para>
This will create a <filename>tmp.schema</filename> file with an XML This will create a <filename>tmp.schema</filename> file with an XML
@ -801,7 +803,7 @@ javac Rabbit.java
Enhance the <classname>Rabbit</classname> class. Enhance the <classname>Rabbit</classname> class.
</para> </para>
<programlisting> <programlisting>
openjpac -p persistence.xml Rabbit.java java org.apache.openjpa.enhance.PCEnhancer -p persistence.xml Rabbit.java
</programlisting> </programlisting>
</listitem> </listitem>
<listitem> <listitem>
@ -809,7 +811,7 @@ openjpac -p persistence.xml Rabbit.java
Refresh the object-relational mappings and database schema. Refresh the object-relational mappings and database schema.
</para> </para>
<programlisting> <programlisting>
mappingtool -p persistence.xml Rabbit.java java org.apache.openjpa.jdbc.meta.MappingTool -p persistence.xml Rabbit.java
</programlisting> </programlisting>
</listitem> </listitem>
</orderedlist> </orderedlist>
@ -889,7 +891,7 @@ javac Snake.java
Enhance the class. Enhance the class.
</para> </para>
<programlisting> <programlisting>
openjpac -p persistence.xml Snake.java java org.apache.openjpa.enhance.PCEnhancer -p persistence.xml Snake.java
</programlisting> </programlisting>
</listitem> </listitem>
<listitem> <listitem>
@ -901,7 +903,7 @@ As we have created a new persistent class, we must map it to the database and
change the schema to match. So run the mapping tool: change the schema to match. So run the mapping tool:
</para> </para>
<programlisting> <programlisting>
mappingtool -p persistence.xml Snake.java java org.apache.openjpa.jdbc.meta.MappingTool -p persistence.xml Snake.java
</programlisting> </programlisting>
</listitem> </listitem>
<listitem> <listitem>
@ -1101,7 +1103,7 @@ enhance the classes.
</para> </para>
<programlisting> <programlisting>
javac Snake.java Rabbit.java javac Snake.java Rabbit.java
openjpac -p persistence.xml Snake.java Rabbit.java java org.apache.openjpa.enhance.PCEnhancer -p persistence.xml Snake.java Rabbit.java
</programlisting> </programlisting>
</listitem> </listitem>
<listitem> <listitem>
@ -1109,7 +1111,7 @@ openjpac -p persistence.xml Snake.java Rabbit.java
Refresh the mappings and database. Refresh the mappings and database.
</para> </para>
<programlisting> <programlisting>
mappingtool -p persistence.xml Snake.java Rabbit.java java org.apache.openjpa.jdbc.meta.MappingTool -p persistence.xml Snake.java Rabbit.java
</programlisting> </programlisting>
</listitem> </listitem>
</orderedlist> </orderedlist>
@ -1302,7 +1304,7 @@ javac *.java ejb/*.java jsp/*.java
Enhance the Car class. Enhance the Car class.
</para> </para>
<programlisting> <programlisting>
openjpac -p persistence.xml Car.java java org.apache.openjpa.enhance.PCEnhancer -p persistence.xml Car.java
</programlisting> </programlisting>
<para> <para>
Run the mapping tool; make sure that your <filename> META-INF/persistence.xml Run the mapping tool; make sure that your <filename> META-INF/persistence.xml
@ -1315,7 +1317,7 @@ include <classname>samples.persistence.j2ee.Car</classname> in the
&lt;config-property name="MetaDataFactory"&gt;Types=samples.persistence.j2ee.Car&lt;/config-property/&gt; &lt;config-property name="MetaDataFactory"&gt;Types=samples.persistence.j2ee.Car&lt;/config-property/&gt;
</programlisting> </programlisting>
<programlisting> <programlisting>
mappingtool -p persistence.xml Car.java java org.apache.openjpa.jdbc.meta.MappingTool -p persistence.xml Car.java
</programlisting> </programlisting>
<para> <para>
Build an J2EE application archive by running Ant against the <filename> Build an J2EE application archive by running Ant against the <filename>

View File

@ -235,7 +235,7 @@ number of lines to skip between sections of code. Defaults to 2.
Code Formatting with the Reverse Mapping Tool Code Formatting with the Reverse Mapping Tool
</title> </title>
<programlisting> <programlisting>
reversemappingtool -cf.spaceBeforeParen true -cf.tabSpaces 4 java org.apache.openjpa.jdbc.meta.ReverseMappingTool -cf.spaceBeforeParen true -cf.tabSpaces 4
</programlisting> </programlisting>
</example> </example>
</section> </section>

View File

@ -4420,7 +4420,7 @@ Add the necessary schema components to the database to match the given XML
document, but don't drop any data: document, but don't drop any data:
</para> </para>
<programlisting> <programlisting>
schematool targetSchema.xml java org.apache.openjpa.jdbc.schema.SchemaTool targetSchema.xml
</programlisting> </programlisting>
</example> </example>
<example id="ref_guide_schema_schematool_script"> <example id="ref_guide_schema_schematool_script">
@ -4432,13 +4432,13 @@ Repeat the same action as the first example, but this time don't change the
database. Instead, write any planned changes to a SQL script: database. Instead, write any planned changes to a SQL script:
</para> </para>
<programlisting> <programlisting>
schematool -f script.sql targetSchema.xml java org.apache.openjpa.jdbc.schema.SchemaTool -f script.sql targetSchema.xml
</programlisting> </programlisting>
<para> <para>
Write a SQL script that will re-create the current database: Write a SQL script that will re-create the current database:
</para> </para>
<programlisting> <programlisting>
schematool -a createDB -f script.sql java org.apache.openjpa.jdbc.schema.SchemaTool -a createDB -f script.sql
</programlisting> </programlisting>
</example> </example>
<example id="ref_guide_schema_schematool_drop"> <example id="ref_guide_schema_schematool_drop">
@ -4449,7 +4449,7 @@ schematool -a createDB -f script.sql
Drop the current database: Drop the current database:
</para> </para>
<programlisting> <programlisting>
schematool -a dropDB java org.apache.openjpa.jdbc.schema.SchemaTool -a dropDB
</programlisting> </programlisting>
</example> </example>
<example id="ref_guide_schema_schematool_reflect"> <example id="ref_guide_schema_schematool_reflect">
@ -4472,7 +4472,7 @@ Write an XML representation of the current schema to file <filename>schema.xml
</filename>. </filename>.
</para> </para>
<programlisting> <programlisting>
schematool -a reflect -f schema.xml java org.apache.openjpa.jdbc.schema.SchemaTool -a reflect -f schema.xml
</programlisting> </programlisting>
</example> </example>
</section> </section>

View File

@ -330,7 +330,7 @@ object-relational mapping data is always synchronized with your persistent class
definitions, without needing to remember to invoke the mapping tool manually. definitions, without needing to remember to invoke the mapping tool manually.
The task's parameters correspond exactly to the long versions of the The task's parameters correspond exactly to the long versions of the
command-line arguments to the <link linkend="ref_guide_mapping_mappingtool"> command-line arguments to the <link linkend="ref_guide_mapping_mappingtool">
<literal> mappingtool</literal></link>. <literal>mappingtool</literal></link>.
</para> </para>
<para> <para>
The mapping tool task accepts a nested <literal>fileset</literal> tag to specify The mapping tool task accepts a nested <literal>fileset</literal> tag to specify

View File

@ -62,7 +62,7 @@ tool Ant task.
Using the Mapping Tool Using the Mapping Tool
</title> </title>
<programlisting> <programlisting>
mappingtool Magazine.java java org.apache.openjpa.jdbc.meta.MappingTool Magazine.java
</programlisting> </programlisting>
</example> </example>
<para> <para>
@ -260,7 +260,7 @@ model.
Creating the Relational Schema from Mappings Creating the Relational Schema from Mappings
</title> </title>
<programlisting> <programlisting>
mappingtool Magazine.java java org.apache.openjpa.jdbc.meta.MappingTool Magazine.java
</programlisting> </programlisting>
</example> </example>
<para> <para>
@ -272,7 +272,7 @@ schemaAction</literal> to <literal>drop</literal>.
Dropping Mappings and Association Schema Dropping Mappings and Association Schema
</title> </title>
<programlisting> <programlisting>
mappingtool -sa drop Magazine.java java org.apache.openjpa.jdbc.meta.MappingTool -sa drop Magazine.java
</programlisting> </programlisting>
</example> </example>
</section> </section>
@ -309,7 +309,7 @@ This example uses your existing mappings to determine the needed schema, then
writes the SQL to create that schema to <filename>create.sql</filename>. writes the SQL to create that schema to <filename>create.sql</filename>.
</para> </para>
<programlisting> <programlisting>
mappingtool -a buildSchema -sa build -sql create.sql Magazine.java java org.apache.openjpa.jdbc.meta.MappingTool -a buildSchema -sa build -sql create.sql Magazine.java
</programlisting> </programlisting>
</example> </example>
<example id="ref_guid_mapping_ddl_part_ddl"> <example id="ref_guid_mapping_ddl_part_ddl">
@ -323,7 +323,7 @@ writes the SQL to add any missing tables and columns to the current schema to
<filename>update.sql</filename>. <filename>update.sql</filename>.
</para> </para>
<programlisting> <programlisting>
mappingtool -a buildSchema -sql update.sql Magazine.java java org.apache.openjpa.jdbc.meta.MappingTool -a buildSchema -sql update.sql Magazine.java
</programlisting> </programlisting>
</example> </example>
</section> </section>
@ -381,7 +381,7 @@ correspond go the long versions of the tool's command line flags.
The setting above corresponds to running the following command: The setting above corresponds to running the following command:
</para> </para>
<programlisting> <programlisting>
mappingtool -a buildSchema -fk true java org.apache.openjpa.jdbc.meta.MappingTool -a buildSchema -fk true
</programlisting> </programlisting>
</example> </example>
</section> </section>
@ -446,7 +446,7 @@ database.
Reflection with the Schema Tool Reflection with the Schema Tool
</title> </title>
<programlisting> <programlisting>
schematool -a reflect -f schema.xml java org.apache.openjpa.jdbc.schema.SchemaTool -a reflect -f schema.xml
</programlisting> </programlisting>
</example> </example>
</listitem> </listitem>
@ -480,7 +480,7 @@ the database. The tool can be run via the included <literal>reversemappingtool
Using the Reverse Mapping Tool Using the Reverse Mapping Tool
</title> </title>
<programlisting> <programlisting>
reversemappingtool -pkg com.xyz -d ~/src -cp customizer.properties schema.xml java org.apache.openjpa.jdbc.meta.ReverseMappingTool -pkg com.xyz -d ~/src -cp customizer.properties schema.xml
</programlisting> </programlisting>
</example> </example>
<para> <para>
@ -824,7 +824,7 @@ default value generated by the reverse mapping tool.
Customizing Reverse Mapping with Properties Customizing Reverse Mapping with Properties
</title> </title>
<programlisting> <programlisting>
reversemappingtool -pkg com.xyz -cp custom.properties schema.xml java org.apache.openjpa.jdbc.meta.ReverseMappingTool -pkg com.xyz -cp custom.properties schema.xml
</programlisting> </programlisting>
<para> <para>
Example <filename>custom.properties</filename>: Example <filename>custom.properties</filename>:
@ -894,7 +894,7 @@ when your mappings are incorrect.
Validating Mappings Validating Mappings
</title> </title>
<programlisting> <programlisting>
mappingtool -a validate Magazine.java java org.apache.openjpa.jdbc.meta.MappingTool -a validate Magazine.java
</programlisting> </programlisting>
</example> </example>
<para> <para>
@ -916,7 +916,7 @@ defaults ( <xref linkend="ref_guide_mapping_defaults"/> ).
Creating the Relational Schema from Mappings Creating the Relational Schema from Mappings
</title> </title>
<programlisting> <programlisting>
mappingtool Magazine.java java org.apache.openjpa.jdbc.meta.MappingTool Magazine.java
</programlisting> </programlisting>
</example> </example>
</section> </section>

View File

@ -138,9 +138,9 @@ are loaded into the JVM. The following sections describe each option.
</secondary> </secondary>
</indexterm> </indexterm>
<para> <para>
The enhancer can be invoked at build time via the included <literal>openjpac The enhancer can be invoked at build time
</literal> script or via its Java class, <classname> via the Java tool,
org.apache.openjpa.enhance.PCEnhancer</classname>. <classname>org.apache.openjpa.enhance.PCEnhancer</classname>.
</para> </para>
<note> <note>
<para> <para>
@ -153,7 +153,7 @@ You can also enhance via Ant; see <xref linkend="ref_guide_integration_enhance"/
Using the OpenJPA Enhancer Using the OpenJPA Enhancer
</title> </title>
<programlisting> <programlisting>
openjpac Magazine.java java org.apache.openjpa.enhance.PCEnhancer Magazine.java
</programlisting> </programlisting>
</example> </example>
<para> <para>
@ -513,8 +513,7 @@ generated identity class. Once the application identity tool has generated the
class code, you can set the <literal>@IdClass</literal> annotation. class code, you can set the <literal>@IdClass</literal> annotation.
</para> </para>
<para> <para>
The application identity tool can be invoked via the included <literal> The application identity tool can be invoked via the Java class,
appidtool</literal> shell/bat script or via its Java class,
<ulink url="../apidocs/org/apache/openjpa/enhance/ApplicationIdTool"> <ulink url="../apidocs/org/apache/openjpa/enhance/ApplicationIdTool">
<classname>org.apache.openjpa.enhance.ApplicationIdTool</classname></ulink>. <classname>org.apache.openjpa.enhance.ApplicationIdTool</classname></ulink>.
</para> </para>
@ -529,7 +528,7 @@ application identity tool's Ant task.
Using the Application Identity Tool Using the Application Identity Tool
</title> </title>
<programlisting> <programlisting>
appidtool -s Id Magazine.java java org.apache.openjpa.enhance.ApplicationIdTool -s Id Magazine.java
</programlisting> </programlisting>
</example> </example>
<para> <para>

View File

@ -86,31 +86,23 @@ You should then proceed to pass in the configuration file you are using to the
enhancer: enhancer:
</para> </para>
<para> <para>
<userinput>openjpac -p persistence.xml Machine.java Crane.java Bulldozer.java <userinput>java org.apache.openjpa.enhance.PCEnhancer -p persistence.xml Machine.java Crane.java Bulldozer.java
Operator.java</userinput>
</para>
<para>
or
</para>
<para>
<userinput>jdoc -p jdo.properties Machine.java Crane.java Bulldozer.java
Operator.java</userinput> Operator.java</userinput>
</para> </para>
</listitem> </listitem>
<listitem> <listitem>
<para> <para>
Similarly, you should pass in the same argument to <literal>mappingtool Similarly, you should pass in the same argument to <literal>org.apache.openjpa.jdbc.meta.MappingTool</literal>:
</literal>:
</para> </para>
<para> <para>
<userinput>mappingtool -p persistence.xml -a buildSchema Machine.java <userinput>java org.apache.openjpa.jdbc.meta.MappingTool -p persistence.xml -a buildSchema Machine.java
Crane.java Bulldozer.java Operator.java</userinput> Crane.java Bulldozer.java Operator.java</userinput>
</para> </para>
<para> <para>
or or
</para> </para>
<para> <para>
<userinput>mappingtool -p jdo.properties -a buildSchema Machine.java Crane.java <userinput>java org.apache.openjpa.jdbc.meta.MappingTool -p jdo.properties -a buildSchema Machine.java Crane.java
Bulldozer.java Operator.java</userinput> Bulldozer.java Operator.java</userinput>
</para> </para>
</listitem> </listitem>