Projekt-Dokumentation (Aktueller Stand von juplo.de) hinzugefĆ¼gt
[website] / dist / hibernate4-maven-plugin-1.0.1 / export-mojo.html
1 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">\r
2 <!-- Generated by Apache Maven Doxia at Jan 15, 2013 -->\r
3 <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">\r
4   <head>\r
5     <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />\r
6     <title>Hibernate 4 Maven Plugin - 
7     hibernate4:export</title>\r
8     <style type="text/css" media="all">\r
9       @import url("./css/maven-base.css");\r
10       @import url("./css/maven-theme.css");\r
11       @import url("./css/site.css");\r
12     </style>\r
13     <link rel="stylesheet" href="./css/print.css" type="text/css" media="print" />\r
14     <meta name="Date-Revision-yyyymmdd" content="20130115" />\r
15     <meta http-equiv="Content-Language" content="en" />\r
16                                                     
17 <script type="text/javascript"><!--
18
19         var _gaq = _gaq || [];
20         _gaq.push(['_setAccount', 'UA-571104-3']);
21         _gaq.push(['_trackPageview']);
22
23         (function() {
24           var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
25           ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
26           var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
27         })();
28
29       //--></script>\r
30                       \r
31   </head>\r
32   <body class="composite">\r
33     <div id="banner">\r
34                     <div id="bannerLeft">\r
35                 Hibernate 4 Maven Plugin\r
36                 </div>\r
37                     <div class="clear">\r
38         <hr/>\r
39       </div>\r
40     </div>\r
41     <div id="breadcrumbs">\r
42             \r
43         \r
44                 <div class="xleft">\r
45         <span id="publishDate">Last Published: 2013-01-15</span>\r
46                   &nbsp;| <span id="projectVersion">Version: 1.0.1</span>\r
47                           |                           <a href="http://juplo.de" class="externalLink" title="juplo">juplo</a>\r
48                           </div>\r
49             <div class="xright">        \r
50         \r
51       </div>\r
52       <div class="clear">\r
53         <hr/>\r
54       </div>\r
55     </div>\r
56     <div id="leftColumn">\r
57       <div id="navcolumn">\r
58              \r
59         \r
60                                 <h5>Overview</h5>\r
61                   <ul>\r
62                   <li class="none">\r
63                           <a href="index.html" title="Introduction">Introduction</a>\r
64             </li>\r
65                   <li class="none">\r
66                           <a href="configuration.html" title="Configuration Examples">Configuration Examples</a>\r
67             </li>\r
68                   <li class="none">\r
69             <strong>Parameter Documentation</strong>\r
70           </li>\r
71                   <li class="none">\r
72                           <a href="debugging.html" title="Enable Debug-Output">Enable Debug-Output</a>\r
73             </li>\r
74                   <li class="none">\r
75                           <a href="force.html" title="Force Exceution">Force Exceution</a>\r
76             </li>\r
77                   <li class="none">\r
78                           <a href="pitfalls.html" title="Known Pitfalls">Known Pitfalls</a>\r
79             </li>\r
80           </ul>\r
81                        <h5>Project Documentation</h5>\r
82                   <ul>\r
83                                                                                                                                                                                                                                                         <li class="collapsed">\r
84                           <a href="project-info.html" title="Project Information">Project Information</a>\r
85                   </li>\r
86                                                                                                                                             <li class="collapsed">\r
87                           <a href="project-reports.html" title="Project Reports">Project Reports</a>\r
88                   </li>\r
89           </ul>\r
90                              <a href="http://maven.apache.org/" title="Built by Maven" class="poweredBy">\r
91         <img class="poweredBy" alt="Built by Maven" src="./images/logos/maven-feather.png" />\r
92       </a>\r
93                    \r
94         \r
95             </div>\r
96     </div>\r
97     <div id="bodyColumn">\r
98       <div id="contentBox">\r
99         
100   
101     <div class="section"><h2>hibernate4:export<a name="hibernate4:export"></a></h2>
102       <p><b>Full name</b>:</p>
103       <p>de.juplo:hibernate4-maven-plugin:1.0.1:export</p>
104       <p><b>Description</b>:</p>
105       <div>Goal which extracts the hibernate-mapping-configuration and exports
106 an according SQL-database-schema.</div>
107       <p><b>Attributes</b>:</p>
108       <ul>
109         <li>Requires a Maven project to be executed.</li>
110         <li>Requires dependency resolution of artifacts in scope: <tt>runtime</tt>.</li>
111         <li>The goal is thread-safe and supports parallel builds.</li>
112         <li>Binds by default to the <a class="externalLink" href="http://maven.apache.org/ref/current/maven-core/lifecycles.html">lifecycle phase</a>: <tt>process-classes</tt>.</li>
113       </ul>
114       <div class="section"><h3>Optional Parameters<a name="Optional_Parameters"></a></h3>
115         <table align="center" class="bodyTable" border="0">
116           <tr class="a">
117             <th align="left">Name</th>
118             <th align="left">Type</th>
119             <th align="left">Since</th>
120             <th align="left">Description</th>
121           </tr>
122           <tr class="b">
123             <td align="left"><b><a href="#delimiter">delimiter</a></b></td>
124             <td align="left"><tt>String</tt></td>
125             <td align="left"><tt>-</tt></td>
126             <td align="left">Delimiter in output-file.<br /><b>Default value is</b>: <tt>;</tt>.<br /><b>User property is</b>: <tt>hibernate.export.schema.delimiter</tt>.</td>
127           </tr>
128           <tr class="a">
129             <td align="left"><b><a href="#driverClassName">driverClassName</a></b></td>
130             <td align="left"><tt>String</tt></td>
131             <td align="left"><tt>-</tt></td>
132             <td align="left">SQL-Driver name.<br /><b>User property is</b>: <tt>hibernate.connection.driver_class</tt>.</td>
133           </tr>
134           <tr class="b">
135             <td align="left"><b><a href="#force">force</a></b></td>
136             <td align="left"><tt>boolean</tt></td>
137             <td align="left"><tt>-</tt></td>
138             <td align="left">Force execution 
139 <p>Force execution, even if no modified or newly added annotated
140 classes where found and the dialect was not changed.</p>
141 <p><tt>skip</tt> takes precedence over <tt>force</tt>.</p><br /><b>Default value is</b>: <tt>false</tt>.<br /><b>User property is</b>: <tt>hibernate.export.force</tt>.</td>
142           </tr>
143           <tr class="a">
144             <td align="left"><b><a href="#format">format</a></b></td>
145             <td align="left"><tt>boolean</tt></td>
146             <td align="left"><tt>-</tt></td>
147             <td align="left">Format output-file.<br /><b>Default value is</b>: <tt>true</tt>.<br /><b>User property is</b>: <tt>hibernate.export.schema.format</tt>.</td>
148           </tr>
149           <tr class="b">
150             <td align="left"><b><a href="#hibernateDialect">hibernateDialect</a></b></td>
151             <td align="left"><tt>String</tt></td>
152             <td align="left"><tt>-</tt></td>
153             <td align="left">Hibernate dialect.<br /><b>User property is</b>: <tt>hibernate.dialect</tt>.</td>
154           </tr>
155           <tr class="a">
156             <td align="left"><b><a href="#hibernateProperties">hibernateProperties</a></b></td>
157             <td align="left"><tt>String</tt></td>
158             <td align="left"><tt>-</tt></td>
159             <td align="left">Path to Hibernate configuration file.<br /><b>Default value is</b>: <tt>${project.build.outputDirectory}/hibernate.properties</tt>.<br /></td>
160           </tr>
161           <tr class="b">
162             <td align="left"><b><a href="#outputDirectory">outputDirectory</a></b></td>
163             <td align="left"><tt>String</tt></td>
164             <td align="left"><tt>-</tt></td>
165             <td align="left">Classes-Directory to scan. 
166 <p>This parameter defaults to the maven build-output-directory for
167 classes. Additonally, all dependencies are scanned for annotated
168 classes.</p><br /><b>User property is</b>: <tt>project.build.outputDirectory</tt>.</td>
169           </tr>
170           <tr class="a">
171             <td align="left"><b><a href="#outputFile">outputFile</a></b></td>
172             <td align="left"><tt>String</tt></td>
173             <td align="left"><tt>-</tt></td>
174             <td align="left">Output file.<br /><b>Default value is</b>: <tt>${project.build.directory}/schema.sql</tt>.<br /><b>User property is</b>: <tt>hibernate.export.schema.filename</tt>.</td>
175           </tr>
176           <tr class="b">
177             <td align="left"><b><a href="#password">password</a></b></td>
178             <td align="left"><tt>String</tt></td>
179             <td align="left"><tt>-</tt></td>
180             <td align="left">Database password<br /><b>User property is</b>: <tt>hibernate.connection.password</tt>.</td>
181           </tr>
182           <tr class="a">
183             <td align="left"><b><a href="#scanTestClasses">scanTestClasses</a></b></td>
184             <td align="left"><tt>boolean</tt></td>
185             <td align="left"><tt>-</tt></td>
186             <td align="left">Wether to scan test-classes too, or not. 
187 <p>If this parameter is set to <tt>true</tt> the test-classes
188 of the artifact will be scanned for hibernate-annotated classes
189 additionally.</p><br /><b>Default value is</b>: <tt>false</tt>.<br /><b>User property is</b>: <tt>hibernate.export.scann_testclasses</tt>.</td>
190           </tr>
191           <tr class="b">
192             <td align="left"><b><a href="#skip">skip</a></b></td>
193             <td align="left"><tt>boolean</tt></td>
194             <td align="left"><tt>-</tt></td>
195             <td align="left">Skip execution 
196 <p>If set to <tt>true</tt>, the execution is skipped.</p>
197 <p>A skipped excecution is signaled via the maven-property
198 <tt>${hibernate.export.skipped}</tt>.</p>
199 <p>The excecution is skipped automatically, if no modified or newly
200 added annotated classes are found and the dialect was not
201 changed.</p><br /><b>Default value is</b>: <tt>false</tt>.<br /><b>User property is</b>: <tt>maven.test.skip</tt>.</td>
202           </tr>
203           <tr class="a">
204             <td align="left"><b><a href="#target">target</a></b></td>
205             <td align="left"><tt>String</tt></td>
206             <td align="left"><tt>-</tt></td>
207             <td align="left">Target of execution: 
208 <ul>
209 <li><b>NONE</b> do nothing - just validate the
210 configuration (forces excecution, signals skip)</li>
211 <li><b>EXPORT</b> create database
212 (<b>DEFAULT!</b>. forces excecution, signals skip)</li>
213 <li><b>SCRIPT</b> export schema to SQL-script</li>
214 <li><b>BOTH</b></li>
215 </ul><br /><b>Default value is</b>: <tt>EXPORT</tt>.<br /><b>User property is</b>: <tt>hibernate.export.target</tt>.</td>
216           </tr>
217           <tr class="b">
218             <td align="left"><b><a href="#testOutputDirectory">testOutputDirectory</a></b></td>
219             <td align="left"><tt>String</tt></td>
220             <td align="left"><tt>-</tt></td>
221             <td align="left">Test-Classes-Directory to scan. 
222 <p>This parameter defaults to the maven build-output-directory for
223 test-classes.</p>
224 <p>This parameter is only used, when <tt>scanTestClasses</tt>
225 is set to <tt>true</tt>!</p><br /><b>User property is</b>: <tt>project.build.testOutputDirectory</tt>.</td>
226           </tr>
227           <tr class="a">
228             <td align="left"><b><a href="#type">type</a></b></td>
229             <td align="left"><tt>String</tt></td>
230             <td align="left"><tt>-</tt></td>
231             <td align="left">Type of execution. 
232 <ul>
233 <li><b>NONE</b> do nothing - just validate the
234 configuration</li>
235 <li><b>CREATE</b> create database-schema</li>
236 <li><b>DROP</b> drop database-schema</li>
237 <li><b>BOTH</b> (<b>DEFAULT!</b>)</li>
238 </ul><br /><b>Default value is</b>: <tt>BOTH</tt>.<br /><b>User property is</b>: <tt>hibernate.export.type</tt>.</td>
239           </tr>
240           <tr class="b">
241             <td align="left"><b><a href="#url">url</a></b></td>
242             <td align="left"><tt>String</tt></td>
243             <td align="left"><tt>-</tt></td>
244             <td align="left">Database URL.<br /><b>User property is</b>: <tt>hibernate.connection.url</tt>.</td>
245           </tr>
246           <tr class="a">
247             <td align="left"><b><a href="#username">username</a></b></td>
248             <td align="left"><tt>String</tt></td>
249             <td align="left"><tt>-</tt></td>
250             <td align="left">Database username<br /><b>User property is</b>: <tt>hibernate.connection.username</tt>.</td>
251           </tr>
252         </table>
253       </div>
254       <div class="section"><h3>Parameter Details<a name="Parameter_Details"></a></h3>
255         <p><b><a name="delimiter">delimiter</a>:</b></p>
256         <div>Delimiter in output-file.</div>
257         <ul>
258           <li><b>Type</b>: <tt>java.lang.String</tt></li>
259           <li><b>Required</b>: <tt>No</tt></li>
260           <li><b>User Property</b>: <tt>hibernate.export.schema.delimiter</tt></li>
261           <li><b>Default</b>: <tt>;</tt></li>
262         </ul><hr /><p><b><a name="driverClassName">driverClassName</a>:</b></p>
263         <div>SQL-Driver name.</div>
264         <ul>
265           <li><b>Type</b>: <tt>java.lang.String</tt></li>
266           <li><b>Required</b>: <tt>No</tt></li>
267           <li><b>User Property</b>: <tt>hibernate.connection.driver_class</tt></li>
268         </ul><hr /><p><b><a name="force">force</a>:</b></p>
269         <div>Force execution 
270 <p>Force execution, even if no modified or newly added annotated
271 classes where found and the dialect was not changed.</p>
272 <p><tt>skip</tt> takes precedence over <tt>force</tt>.</p></div>
273         <ul>
274           <li><b>Type</b>: <tt>boolean</tt></li>
275           <li><b>Required</b>: <tt>No</tt></li>
276           <li><b>User Property</b>: <tt>hibernate.export.force</tt></li>
277           <li><b>Default</b>: <tt>false</tt></li>
278         </ul><hr /><p><b><a name="format">format</a>:</b></p>
279         <div>Format output-file.</div>
280         <ul>
281           <li><b>Type</b>: <tt>boolean</tt></li>
282           <li><b>Required</b>: <tt>No</tt></li>
283           <li><b>User Property</b>: <tt>hibernate.export.schema.format</tt></li>
284           <li><b>Default</b>: <tt>true</tt></li>
285         </ul><hr /><p><b><a name="hibernateDialect">hibernateDialect</a>:</b></p>
286         <div>Hibernate dialect.</div>
287         <ul>
288           <li><b>Type</b>: <tt>java.lang.String</tt></li>
289           <li><b>Required</b>: <tt>No</tt></li>
290           <li><b>User Property</b>: <tt>hibernate.dialect</tt></li>
291         </ul><hr /><p><b><a name="hibernateProperties">hibernateProperties</a>:</b></p>
292         <div>Path to Hibernate configuration file.</div>
293         <ul>
294           <li><b>Type</b>: <tt>java.lang.String</tt></li>
295           <li><b>Required</b>: <tt>No</tt></li>
296           <li><b>Default</b>: <tt>${project.build.outputDirectory}/hibernate.properties</tt></li>
297         </ul><hr /><p><b><a name="outputDirectory">outputDirectory</a>:</b></p>
298         <div>Classes-Directory to scan. 
299 <p>This parameter defaults to the maven build-output-directory for
300 classes. Additonally, all dependencies are scanned for annotated
301 classes.</p></div>
302         <ul>
303           <li><b>Type</b>: <tt>java.lang.String</tt></li>
304           <li><b>Required</b>: <tt>No</tt></li>
305           <li><b>User Property</b>: <tt>project.build.outputDirectory</tt></li>
306         </ul><hr /><p><b><a name="outputFile">outputFile</a>:</b></p>
307         <div>Output file.</div>
308         <ul>
309           <li><b>Type</b>: <tt>java.lang.String</tt></li>
310           <li><b>Required</b>: <tt>No</tt></li>
311           <li><b>User Property</b>: <tt>hibernate.export.schema.filename</tt></li>
312           <li><b>Default</b>: <tt>${project.build.directory}/schema.sql</tt></li>
313         </ul><hr /><p><b><a name="password">password</a>:</b></p>
314         <div>Database password</div>
315         <ul>
316           <li><b>Type</b>: <tt>java.lang.String</tt></li>
317           <li><b>Required</b>: <tt>No</tt></li>
318           <li><b>User Property</b>: <tt>hibernate.connection.password</tt></li>
319         </ul><hr /><p><b><a name="scanTestClasses">scanTestClasses</a>:</b></p>
320         <div>Wether to scan test-classes too, or not. 
321 <p>If this parameter is set to <tt>true</tt> the test-classes
322 of the artifact will be scanned for hibernate-annotated classes
323 additionally.</p></div>
324         <ul>
325           <li><b>Type</b>: <tt>boolean</tt></li>
326           <li><b>Required</b>: <tt>No</tt></li>
327           <li><b>User Property</b>: <tt>hibernate.export.scann_testclasses</tt></li>
328           <li><b>Default</b>: <tt>false</tt></li>
329         </ul><hr /><p><b><a name="skip">skip</a>:</b></p>
330         <div>Skip execution 
331 <p>If set to <tt>true</tt>, the execution is skipped.</p>
332 <p>A skipped excecution is signaled via the maven-property
333 <tt>${hibernate.export.skipped}</tt>.</p>
334 <p>The excecution is skipped automatically, if no modified or newly
335 added annotated classes are found and the dialect was not
336 changed.</p></div>
337         <ul>
338           <li><b>Type</b>: <tt>boolean</tt></li>
339           <li><b>Required</b>: <tt>No</tt></li>
340           <li><b>User Property</b>: <tt>maven.test.skip</tt></li>
341           <li><b>Default</b>: <tt>false</tt></li>
342         </ul><hr /><p><b><a name="target">target</a>:</b></p>
343         <div>Target of execution: 
344 <ul>
345 <li><b>NONE</b> do nothing - just validate the
346 configuration (forces excecution, signals skip)</li>
347 <li><b>EXPORT</b> create database
348 (<b>DEFAULT!</b>. forces excecution, signals skip)</li>
349 <li><b>SCRIPT</b> export schema to SQL-script</li>
350 <li><b>BOTH</b></li>
351 </ul></div>
352         <ul>
353           <li><b>Type</b>: <tt>java.lang.String</tt></li>
354           <li><b>Required</b>: <tt>No</tt></li>
355           <li><b>User Property</b>: <tt>hibernate.export.target</tt></li>
356           <li><b>Default</b>: <tt>EXPORT</tt></li>
357         </ul><hr /><p><b><a name="testOutputDirectory">testOutputDirectory</a>:</b></p>
358         <div>Test-Classes-Directory to scan. 
359 <p>This parameter defaults to the maven build-output-directory for
360 test-classes.</p>
361 <p>This parameter is only used, when <tt>scanTestClasses</tt>
362 is set to <tt>true</tt>!</p></div>
363         <ul>
364           <li><b>Type</b>: <tt>java.lang.String</tt></li>
365           <li><b>Required</b>: <tt>No</tt></li>
366           <li><b>User Property</b>: <tt>project.build.testOutputDirectory</tt></li>
367         </ul><hr /><p><b><a name="type">type</a>:</b></p>
368         <div>Type of execution. 
369 <ul>
370 <li><b>NONE</b> do nothing - just validate the
371 configuration</li>
372 <li><b>CREATE</b> create database-schema</li>
373 <li><b>DROP</b> drop database-schema</li>
374 <li><b>BOTH</b> (<b>DEFAULT!</b>)</li>
375 </ul></div>
376         <ul>
377           <li><b>Type</b>: <tt>java.lang.String</tt></li>
378           <li><b>Required</b>: <tt>No</tt></li>
379           <li><b>User Property</b>: <tt>hibernate.export.type</tt></li>
380           <li><b>Default</b>: <tt>BOTH</tt></li>
381         </ul><hr /><p><b><a name="url">url</a>:</b></p>
382         <div>Database URL.</div>
383         <ul>
384           <li><b>Type</b>: <tt>java.lang.String</tt></li>
385           <li><b>Required</b>: <tt>No</tt></li>
386           <li><b>User Property</b>: <tt>hibernate.connection.url</tt></li>
387         </ul><hr /><p><b><a name="username">username</a>:</b></p>
388         <div>Database username</div>
389         <ul>
390           <li><b>Type</b>: <tt>java.lang.String</tt></li>
391           <li><b>Required</b>: <tt>No</tt></li>
392           <li><b>User Property</b>: <tt>hibernate.connection.username</tt></li>
393         </ul>
394       </div>
395     </div>
396   
397 \r
398       </div>\r
399     </div>\r
400     <div class="clear">\r
401       <hr/>\r
402     </div>\r
403     <div id="footer">\r
404       <div class="xright">Copyright &#169;                   2013.\r
405           All Rights Reserved.      \r
406         \r
407       </div>\r
408       <div class="clear">\r
409         <hr/>\r
410       </div>\r
411     </div>\r
412   </body>\r
413 </html>\r