| <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> |
| <!-- NewPage --> |
| <html lang="it"> |
| <head> |
| <!-- Generated by javadoc (version 1.7.0_80) on Thu Jun 14 10:04:01 CEST 2018 --> |
| <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> |
| <title>ApplicationIdTool (OpenJPA Parent POM 2.4.3 API)</title> |
| <meta name="date" content="2018-06-14"> |
| <link rel="stylesheet" type="text/css" href="../../../../stylesheet.css" title="Style"> |
| </head> |
| <body> |
| <script type="text/javascript"><!-- |
| if (location.href.indexOf('is-external=true') == -1) { |
| parent.document.title="ApplicationIdTool (OpenJPA Parent POM 2.4.3 API)"; |
| } |
| //--> |
| </script> |
| <noscript> |
| <div>JavaScript is disabled on your browser.</div> |
| </noscript> |
| <!-- ========= START OF TOP NAVBAR ======= --> |
| <div class="topNav"><a name="navbar_top"> |
| <!-- --> |
| </a><a href="#skip-navbar_top" title="Skip navigation links"></a><a name="navbar_top_firstrow"> |
| <!-- --> |
| </a> |
| <ul class="navList" title="Navigation"> |
| <li><a href="../../../../overview-summary.html">Overview</a></li> |
| <li><a href="package-summary.html">Package</a></li> |
| <li class="navBarCell1Rev">Class</li> |
| <li><a href="class-use/ApplicationIdTool.html">Use</a></li> |
| <li><a href="package-tree.html">Tree</a></li> |
| <li><a href="../../../../deprecated-list.html">Deprecated</a></li> |
| <li><a href="../../../../index-all.html">Index</a></li> |
| <li><a href="../../../../help-doc.html">Help</a></li> |
| </ul> |
| </div> |
| <div class="subNav"> |
| <ul class="navList"> |
| <li>Prev Class</li> |
| <li><a href="../../../../org/apache/openjpa/enhance/ApplicationIdTool.Flags.html" title="class in org.apache.openjpa.enhance"><span class="strong">Next Class</span></a></li> |
| </ul> |
| <ul class="navList"> |
| <li><a href="../../../../index.html?org/apache/openjpa/enhance/ApplicationIdTool.html" target="_top">Frames</a></li> |
| <li><a href="ApplicationIdTool.html" target="_top">No Frames</a></li> |
| </ul> |
| <ul class="navList" id="allclasses_navbar_top"> |
| <li><a href="../../../../allclasses-noframe.html">All Classes</a></li> |
| </ul> |
| <div> |
| <script type="text/javascript"><!-- |
| allClassesLink = document.getElementById("allclasses_navbar_top"); |
| if(window==top) { |
| allClassesLink.style.display = "block"; |
| } |
| else { |
| allClassesLink.style.display = "none"; |
| } |
| //--> |
| </script> |
| </div> |
| <div> |
| <ul class="subNavList"> |
| <li>Summary: </li> |
| <li><a href="#nested_class_summary">Nested</a> | </li> |
| <li><a href="#field_summary">Field</a> | </li> |
| <li><a href="#constructor_summary">Constr</a> | </li> |
| <li><a href="#method_summary">Method</a></li> |
| </ul> |
| <ul class="subNavList"> |
| <li>Detail: </li> |
| <li><a href="#field_detail">Field</a> | </li> |
| <li><a href="#constructor_detail">Constr</a> | </li> |
| <li><a href="#method_detail">Method</a></li> |
| </ul> |
| </div> |
| <a name="skip-navbar_top"> |
| <!-- --> |
| </a></div> |
| <!-- ========= END OF TOP NAVBAR ========= --> |
| <!-- ======== START OF CLASS DATA ======== --> |
| <div class="header"> |
| <div class="subTitle">org.apache.openjpa.enhance</div> |
| <h2 title="Class ApplicationIdTool" class="title">Class ApplicationIdTool</h2> |
| </div> |
| <div class="contentContainer"> |
| <ul class="inheritance"> |
| <li><a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">java.lang.Object</a></li> |
| <li> |
| <ul class="inheritance"> |
| <li>org.apache.openjpa.enhance.ApplicationIdTool</li> |
| </ul> |
| </li> |
| </ul> |
| <div class="description"> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <hr> |
| <br> |
| <pre>public class <span class="strong">ApplicationIdTool</span> |
| extends <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a></pre> |
| <div class="block">Generates a class appropriate for use as an application identity class.</div> |
| <dl><dt><span class="strong">Author:</span></dt> |
| <dd>Patrick Linskey, Abe White</dd></dl> |
| </li> |
| </ul> |
| </div> |
| <div class="summary"> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <!-- ======== NESTED CLASS SUMMARY ======== --> |
| <ul class="blockList"> |
| <li class="blockList"><a name="nested_class_summary"> |
| <!-- --> |
| </a> |
| <h3>Nested Class Summary</h3> |
| <table class="overviewSummary" border="0" cellpadding="3" cellspacing="0" summary="Nested Class Summary table, listing nested classes, and an explanation"> |
| <caption><span>Nested Classes</span><span class="tabEnd"> </span></caption> |
| <tr> |
| <th class="colFirst" scope="col">Modifier and Type</th> |
| <th class="colLast" scope="col">Class and Description</th> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><code>static class </code></td> |
| <td class="colLast"><code><strong><a href="../../../../org/apache/openjpa/enhance/ApplicationIdTool.Flags.html" title="class in org.apache.openjpa.enhance">ApplicationIdTool.Flags</a></strong></code> |
| <div class="block">Run flags.</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><code>static interface </code></td> |
| <td class="colLast"><code><strong><a href="../../../../org/apache/openjpa/enhance/ApplicationIdTool.ObjectIdLoader.html" title="interface in org.apache.openjpa.enhance">ApplicationIdTool.ObjectIdLoader</a></strong></code> |
| <div class="block">Interface implemented by metadata factories that can load non-existant |
| object id classes.</div> |
| </td> |
| </tr> |
| </table> |
| </li> |
| </ul> |
| <!-- =========== FIELD SUMMARY =========== --> |
| <ul class="blockList"> |
| <li class="blockList"><a name="field_summary"> |
| <!-- --> |
| </a> |
| <h3>Field Summary</h3> |
| <table class="overviewSummary" border="0" cellpadding="3" cellspacing="0" summary="Field Summary table, listing fields, and an explanation"> |
| <caption><span>Fields</span><span class="tabEnd"> </span></caption> |
| <tr> |
| <th class="colFirst" scope="col">Modifier and Type</th> |
| <th class="colLast" scope="col">Field and Description</th> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><code>static <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td> |
| <td class="colLast"><code><strong><a href="../../../../org/apache/openjpa/enhance/ApplicationIdTool.html#TOKEN_DEFAULT">TOKEN_DEFAULT</a></strong></code> </td> |
| </tr> |
| </table> |
| </li> |
| </ul> |
| <!-- ======== CONSTRUCTOR SUMMARY ======== --> |
| <ul class="blockList"> |
| <li class="blockList"><a name="constructor_summary"> |
| <!-- --> |
| </a> |
| <h3>Constructor Summary</h3> |
| <table class="overviewSummary" border="0" cellpadding="3" cellspacing="0" summary="Constructor Summary table, listing constructors, and an explanation"> |
| <caption><span>Constructors</span><span class="tabEnd"> </span></caption> |
| <tr> |
| <th class="colOne" scope="col">Constructor and Description</th> |
| </tr> |
| <tr class="altColor"> |
| <td class="colOne"><code><strong><a href="../../../../org/apache/openjpa/enhance/ApplicationIdTool.html#ApplicationIdTool(org.apache.openjpa.conf.OpenJPAConfiguration,%20java.lang.Class)">ApplicationIdTool</a></strong>(<a href="../../../../org/apache/openjpa/conf/OpenJPAConfiguration.html" title="interface in org.apache.openjpa.conf">OpenJPAConfiguration</a> conf, |
| <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</a> type)</code> |
| <div class="block">Constructs a new ApplicationIdTool capable of generating an |
| object id class for <code>type</code>.</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colOne"><code><strong><a href="../../../../org/apache/openjpa/enhance/ApplicationIdTool.html#ApplicationIdTool(org.apache.openjpa.conf.OpenJPAConfiguration,%20java.lang.Class,%20org.apache.openjpa.meta.ClassMetaData)">ApplicationIdTool</a></strong>(<a href="../../../../org/apache/openjpa/conf/OpenJPAConfiguration.html" title="interface in org.apache.openjpa.conf">OpenJPAConfiguration</a> conf, |
| <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</a> type, |
| <a href="../../../../org/apache/openjpa/meta/ClassMetaData.html" title="class in org.apache.openjpa.meta">ClassMetaData</a> meta)</code> |
| <div class="block">Constructs a new tool instance capable of generating an |
| object id class for <code>meta</code>.</div> |
| </td> |
| </tr> |
| </table> |
| </li> |
| </ul> |
| <!-- ========== METHOD SUMMARY =========== --> |
| <ul class="blockList"> |
| <li class="blockList"><a name="method_summary"> |
| <!-- --> |
| </a> |
| <h3>Method Summary</h3> |
| <table class="overviewSummary" border="0" cellpadding="3" cellspacing="0" summary="Method Summary table, listing methods, and an explanation"> |
| <caption><span>Methods</span><span class="tabEnd"> </span></caption> |
| <tr> |
| <th class="colFirst" scope="col">Modifier and Type</th> |
| <th class="colLast" scope="col">Method and Description</th> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><code><a href="http://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td> |
| <td class="colLast"><code><strong><a href="../../../../org/apache/openjpa/enhance/ApplicationIdTool.html#getCode()">getCode</a></strong>()</code> |
| <div class="block">Return the code generated for the application id, or null |
| if invalid class or the <a href="../../../../org/apache/openjpa/enhance/ApplicationIdTool.html#run()"><code>run()</code></a> method has not been called.</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><code><a href="../../../../org/apache/openjpa/lib/util/CodeFormat.html" title="class in org.apache.openjpa.lib.util">CodeFormat</a></code></td> |
| <td class="colLast"><code><strong><a href="../../../../org/apache/openjpa/enhance/ApplicationIdTool.html#getCodeFormat()">getCodeFormat</a></strong>()</code> |
| <div class="block">The code formatter for the generated Java code.</div> |
| </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><code><a href="http://docs.oracle.com/javase/6/docs/api/java/io/File.html?is-external=true" title="class or interface in java.io">File</a></code></td> |
| <td class="colLast"><code><strong><a href="../../../../org/apache/openjpa/enhance/ApplicationIdTool.html#getDirectory()">getDirectory</a></strong>()</code> |
| <div class="block">The directory to write source to.</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><code>boolean</code></td> |
| <td class="colLast"><code><strong><a href="../../../../org/apache/openjpa/enhance/ApplicationIdTool.html#getIgnoreErrors()">getIgnoreErrors</a></strong>()</code> |
| <div class="block">Return false if this tool is configured to throw an exception on |
| an attempt to generate an id class for a type that does not use |
| application identity.</div> |
| </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><code><a href="http://docs.oracle.com/javase/6/docs/api/java/util/Set.html?is-external=true" title="class or interface in java.util">Set</a></code></td> |
| <td class="colLast"><code><strong><a href="../../../../org/apache/openjpa/enhance/ApplicationIdTool.html#getImportPackages()">getImportPackages</a></strong>()</code> |
| <div class="block">Returns the collection of packages that need to be imported.</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><code><a href="../../../../org/apache/openjpa/meta/ClassMetaData.html" title="class in org.apache.openjpa.meta">ClassMetaData</a></code></td> |
| <td class="colLast"><code><strong><a href="../../../../org/apache/openjpa/enhance/ApplicationIdTool.html#getMetaData()">getMetaData</a></strong>()</code> |
| <div class="block">Return metadata for the type we are generating an application id for.</div> |
| </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><code><a href="http://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td> |
| <td class="colLast"><code><strong><a href="../../../../org/apache/openjpa/enhance/ApplicationIdTool.html#getToken()">getToken</a></strong>()</code> |
| <div class="block">The token to use to separate stringified primary key field values.</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><code><a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</a></code></td> |
| <td class="colLast"><code><strong><a href="../../../../org/apache/openjpa/enhance/ApplicationIdTool.html#getType()">getType</a></strong>()</code> |
| <div class="block">Return the type we are generating an application id for.</div> |
| </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><code><a href="http://docs.oracle.com/javase/6/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io">Writer</a></code></td> |
| <td class="colLast"><code><strong><a href="../../../../org/apache/openjpa/enhance/ApplicationIdTool.html#getWriter()">getWriter</a></strong>()</code> |
| <div class="block">The writer to write source to, or null to write to default file.</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><code>boolean</code></td> |
| <td class="colLast"><code><strong><a href="../../../../org/apache/openjpa/enhance/ApplicationIdTool.html#isInnerClass()">isInnerClass</a></strong>()</code> |
| <div class="block">Returns true if the application identity class should be an inner class.</div> |
| </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><code>static void</code></td> |
| <td class="colLast"><code><strong><a href="../../../../org/apache/openjpa/enhance/ApplicationIdTool.html#main(java.lang.String[])">main</a></strong>(<a href="http://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>[] args)</code> |
| <div class="block">Usage: java org.apache.openjpa.enhance.ApplicationIdTool [option]* |
| <class name | .java file | .class file | .jdo file>+ |
| Where the following options are recognized.</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><code>void</code></td> |
| <td class="colLast"><code><strong><a href="../../../../org/apache/openjpa/enhance/ApplicationIdTool.html#record()">record</a></strong>()</code> |
| <div class="block">Writes the generated code to the proper file.</div> |
| </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><code>boolean</code></td> |
| <td class="colLast"><code><strong><a href="../../../../org/apache/openjpa/enhance/ApplicationIdTool.html#run()">run</a></strong>()</code> |
| <div class="block">Generates the sourcecode for the application id class; returns |
| false if the class is invalid.</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><code>static boolean</code></td> |
| <td class="colLast"><code><strong><a href="../../../../org/apache/openjpa/enhance/ApplicationIdTool.html#run(org.apache.openjpa.conf.OpenJPAConfiguration,%20java.lang.String[],%20org.apache.openjpa.enhance.ApplicationIdTool.Flags,%20java.lang.ClassLoader)">run</a></strong>(<a href="../../../../org/apache/openjpa/conf/OpenJPAConfiguration.html" title="interface in org.apache.openjpa.conf">OpenJPAConfiguration</a> conf, |
| <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>[] args, |
| <a href="../../../../org/apache/openjpa/enhance/ApplicationIdTool.Flags.html" title="class in org.apache.openjpa.enhance">ApplicationIdTool.Flags</a> flags, |
| <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/ClassLoader.html?is-external=true" title="class or interface in java.lang">ClassLoader</a> loader)</code> |
| <div class="block">Run the tool.</div> |
| </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><code>static boolean</code></td> |
| <td class="colLast"><code><strong><a href="../../../../org/apache/openjpa/enhance/ApplicationIdTool.html#run(org.apache.openjpa.conf.OpenJPAConfiguration,%20java.lang.String[],%20org.apache.openjpa.lib.util.Options)">run</a></strong>(<a href="../../../../org/apache/openjpa/conf/OpenJPAConfiguration.html" title="interface in org.apache.openjpa.conf">OpenJPAConfiguration</a> conf, |
| <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>[] args, |
| <a href="../../../../org/apache/openjpa/lib/util/Options.html" title="class in org.apache.openjpa.lib.util">Options</a> opts)</code> |
| <div class="block">Run the application id tool with the given command-line and |
| given configuration.</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><code>void</code></td> |
| <td class="colLast"><code><strong><a href="../../../../org/apache/openjpa/enhance/ApplicationIdTool.html#setCodeFormat(org.apache.openjpa.lib.util.CodeFormat)">setCodeFormat</a></strong>(<a href="../../../../org/apache/openjpa/lib/util/CodeFormat.html" title="class in org.apache.openjpa.lib.util">CodeFormat</a> format)</code> |
| <div class="block">Set the code formatter for the generated Java code.</div> |
| </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><code>void</code></td> |
| <td class="colLast"><code><strong><a href="../../../../org/apache/openjpa/enhance/ApplicationIdTool.html#setDirectory(java.io.File)">setDirectory</a></strong>(<a href="http://docs.oracle.com/javase/6/docs/api/java/io/File.html?is-external=true" title="class or interface in java.io">File</a> dir)</code> |
| <div class="block">The directory to write source to.</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><code>void</code></td> |
| <td class="colLast"><code><strong><a href="../../../../org/apache/openjpa/enhance/ApplicationIdTool.html#setIgnoreErrors(boolean)">setIgnoreErrors</a></strong>(boolean ignore)</code> |
| <div class="block">Set to false if this tool should throw an exception on |
| an attempt to generate an id class for a type that does not use |
| application identity.</div> |
| </td> |
| </tr> |
| <tr class="altColor"> |
| <td class="colFirst"><code>void</code></td> |
| <td class="colLast"><code><strong><a href="../../../../org/apache/openjpa/enhance/ApplicationIdTool.html#setToken(java.lang.String)">setToken</a></strong>(<a href="http://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> token)</code> |
| <div class="block">The token to use to separate stringified primary key field values.</div> |
| </td> |
| </tr> |
| <tr class="rowColor"> |
| <td class="colFirst"><code>void</code></td> |
| <td class="colLast"><code><strong><a href="../../../../org/apache/openjpa/enhance/ApplicationIdTool.html#setWriter(java.io.Writer)">setWriter</a></strong>(<a href="http://docs.oracle.com/javase/6/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io">Writer</a> writer)</code> |
| <div class="block">The writer to write source to, or null to write to default file.</div> |
| </td> |
| </tr> |
| </table> |
| <ul class="blockList"> |
| <li class="blockList"><a name="methods_inherited_from_class_java.lang.Object"> |
| <!-- --> |
| </a> |
| <h3>Methods inherited from class java.lang.<a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a></h3> |
| <code><a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#clone()" title="class or interface in java.lang">clone</a>, <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#equals(java.lang.Object)" title="class or interface in java.lang">equals</a>, <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#finalize()" title="class or interface in java.lang">finalize</a>, <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#getClass()" title="class or interface in java.lang">getClass</a>, <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#hashCode()" title="class or interface in java.lang">hashCode</a>, <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#notify()" title="class or interface in java.lang">notify</a>, <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#notifyAll()" title="class or interface in java.lang">notifyAll</a>, <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#toString()" title="class or interface in java.lang">toString</a>, <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#wait()" title="class or interface in java.lang">wait</a>, <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#wait(long)" title="class or interface in java.lang">wait</a>, <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#wait(long,%20int)" title="class or interface in java.lang">wait</a></code></li> |
| </ul> |
| </li> |
| </ul> |
| </li> |
| </ul> |
| </div> |
| <div class="details"> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <!-- ============ FIELD DETAIL =========== --> |
| <ul class="blockList"> |
| <li class="blockList"><a name="field_detail"> |
| <!-- --> |
| </a> |
| <h3>Field Detail</h3> |
| <a name="TOKEN_DEFAULT"> |
| <!-- --> |
| </a> |
| <ul class="blockListLast"> |
| <li class="blockList"> |
| <h4>TOKEN_DEFAULT</h4> |
| <pre>public static final <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> TOKEN_DEFAULT</pre> |
| <dl><dt><span class="strong">See Also:</span></dt><dd><a href="../../../../constant-values.html#org.apache.openjpa.enhance.ApplicationIdTool.TOKEN_DEFAULT">Constant Field Values</a></dd></dl> |
| </li> |
| </ul> |
| </li> |
| </ul> |
| <!-- ========= CONSTRUCTOR DETAIL ======== --> |
| <ul class="blockList"> |
| <li class="blockList"><a name="constructor_detail"> |
| <!-- --> |
| </a> |
| <h3>Constructor Detail</h3> |
| <a name="ApplicationIdTool(org.apache.openjpa.conf.OpenJPAConfiguration, java.lang.Class)"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>ApplicationIdTool</h4> |
| <pre>public ApplicationIdTool(<a href="../../../../org/apache/openjpa/conf/OpenJPAConfiguration.html" title="interface in org.apache.openjpa.conf">OpenJPAConfiguration</a> conf, |
| <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</a> type)</pre> |
| <div class="block">Constructs a new ApplicationIdTool capable of generating an |
| object id class for <code>type</code>.</div> |
| </li> |
| </ul> |
| <a name="ApplicationIdTool(org.apache.openjpa.conf.OpenJPAConfiguration, java.lang.Class, org.apache.openjpa.meta.ClassMetaData)"> |
| <!-- --> |
| </a> |
| <ul class="blockListLast"> |
| <li class="blockList"> |
| <h4>ApplicationIdTool</h4> |
| <pre>public ApplicationIdTool(<a href="../../../../org/apache/openjpa/conf/OpenJPAConfiguration.html" title="interface in org.apache.openjpa.conf">OpenJPAConfiguration</a> conf, |
| <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</a> type, |
| <a href="../../../../org/apache/openjpa/meta/ClassMetaData.html" title="class in org.apache.openjpa.meta">ClassMetaData</a> meta)</pre> |
| <div class="block">Constructs a new tool instance capable of generating an |
| object id class for <code>meta</code>.</div> |
| </li> |
| </ul> |
| </li> |
| </ul> |
| <!-- ============ METHOD DETAIL ========== --> |
| <ul class="blockList"> |
| <li class="blockList"><a name="method_detail"> |
| <!-- --> |
| </a> |
| <h3>Method Detail</h3> |
| <a name="getIgnoreErrors()"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getIgnoreErrors</h4> |
| <pre>public boolean getIgnoreErrors()</pre> |
| <div class="block">Return false if this tool is configured to throw an exception on |
| an attempt to generate an id class for a type that does not use |
| application identity.</div> |
| </li> |
| </ul> |
| <a name="setIgnoreErrors(boolean)"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>setIgnoreErrors</h4> |
| <pre>public void setIgnoreErrors(boolean ignore)</pre> |
| <div class="block">Set to false if this tool should throw an exception on |
| an attempt to generate an id class for a type that does not use |
| application identity.</div> |
| </li> |
| </ul> |
| <a name="getCodeFormat()"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getCodeFormat</h4> |
| <pre>public <a href="../../../../org/apache/openjpa/lib/util/CodeFormat.html" title="class in org.apache.openjpa.lib.util">CodeFormat</a> getCodeFormat()</pre> |
| <div class="block">The code formatter for the generated Java code.</div> |
| </li> |
| </ul> |
| <a name="setCodeFormat(org.apache.openjpa.lib.util.CodeFormat)"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>setCodeFormat</h4> |
| <pre>public void setCodeFormat(<a href="../../../../org/apache/openjpa/lib/util/CodeFormat.html" title="class in org.apache.openjpa.lib.util">CodeFormat</a> format)</pre> |
| <div class="block">Set the code formatter for the generated Java code.</div> |
| </li> |
| </ul> |
| <a name="getDirectory()"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getDirectory</h4> |
| <pre>public <a href="http://docs.oracle.com/javase/6/docs/api/java/io/File.html?is-external=true" title="class or interface in java.io">File</a> getDirectory()</pre> |
| <div class="block">The directory to write source to. Defaults to the directory |
| of the Java file for the set type. If the given directory does not |
| match the package of the object id, the package structure will be |
| created below the directory.</div> |
| </li> |
| </ul> |
| <a name="setDirectory(java.io.File)"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>setDirectory</h4> |
| <pre>public void setDirectory(<a href="http://docs.oracle.com/javase/6/docs/api/java/io/File.html?is-external=true" title="class or interface in java.io">File</a> dir)</pre> |
| <div class="block">The directory to write source to. Defaults to the directory |
| of the Java file for the set type. If the given directory does not |
| match the package of the object id, the package structure will be |
| created below the directory.</div> |
| </li> |
| </ul> |
| <a name="getToken()"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getToken</h4> |
| <pre>public <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> getToken()</pre> |
| <div class="block">The token to use to separate stringified primary key field values.</div> |
| </li> |
| </ul> |
| <a name="setToken(java.lang.String)"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>setToken</h4> |
| <pre>public void setToken(<a href="http://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> token)</pre> |
| <div class="block">The token to use to separate stringified primary key field values.</div> |
| </li> |
| </ul> |
| <a name="getWriter()"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getWriter</h4> |
| <pre>public <a href="http://docs.oracle.com/javase/6/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io">Writer</a> getWriter()</pre> |
| <div class="block">The writer to write source to, or null to write to default file.</div> |
| </li> |
| </ul> |
| <a name="setWriter(java.io.Writer)"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>setWriter</h4> |
| <pre>public void setWriter(<a href="http://docs.oracle.com/javase/6/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io">Writer</a> writer)</pre> |
| <div class="block">The writer to write source to, or null to write to default file.</div> |
| </li> |
| </ul> |
| <a name="getType()"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getType</h4> |
| <pre>public <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</a> getType()</pre> |
| <div class="block">Return the type we are generating an application id for.</div> |
| </li> |
| </ul> |
| <a name="getMetaData()"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getMetaData</h4> |
| <pre>public <a href="../../../../org/apache/openjpa/meta/ClassMetaData.html" title="class in org.apache.openjpa.meta">ClassMetaData</a> getMetaData()</pre> |
| <div class="block">Return metadata for the type we are generating an application id for.</div> |
| </li> |
| </ul> |
| <a name="getCode()"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getCode</h4> |
| <pre>public <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> getCode()</pre> |
| <div class="block">Return the code generated for the application id, or null |
| if invalid class or the <a href="../../../../org/apache/openjpa/enhance/ApplicationIdTool.html#run()"><code>run()</code></a> method has not been called.</div> |
| </li> |
| </ul> |
| <a name="isInnerClass()"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>isInnerClass</h4> |
| <pre>public boolean isInnerClass()</pre> |
| <div class="block">Returns true if the application identity class should be an inner class.</div> |
| </li> |
| </ul> |
| <a name="run()"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>run</h4> |
| <pre>public boolean run()</pre> |
| <div class="block">Generates the sourcecode for the application id class; returns |
| false if the class is invalid.</div> |
| </li> |
| </ul> |
| <a name="record()"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>record</h4> |
| <pre>public void record() |
| throws <a href="http://docs.oracle.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre> |
| <div class="block">Writes the generated code to the proper file.</div> |
| <dl><dt><span class="strong">Throws:</span></dt> |
| <dd><code><a href="http://docs.oracle.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code></dd></dl> |
| </li> |
| </ul> |
| <a name="getImportPackages()"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getImportPackages</h4> |
| <pre>public <a href="http://docs.oracle.com/javase/6/docs/api/java/util/Set.html?is-external=true" title="class or interface in java.util">Set</a> getImportPackages()</pre> |
| <div class="block">Returns the collection of packages that need to be imported.</div> |
| </li> |
| </ul> |
| <a name="main(java.lang.String[])"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>main</h4> |
| <pre>public static void main(<a href="http://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>[] args) |
| throws <a href="http://docs.oracle.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a>, |
| <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/ClassNotFoundException.html?is-external=true" title="class or interface in java.lang">ClassNotFoundException</a></pre> |
| <div class="block">Usage: java org.apache.openjpa.enhance.ApplicationIdTool [option]* |
| <class name | .java file | .class file | .jdo file>+ |
| Where the following options are recognized. |
| <ul> |
| <li><i>-properties/-p <properties file></i>: The path to a OpenJPA |
| properties file containing information as outlined in |
| <a href="../../../../org/apache/openjpa/lib/conf/Configuration.html" title="interface in org.apache.openjpa.lib.conf"><code>Configuration</code></a>; optional.</li> |
| <li><i>-<property name> <property value></i>: All bean |
| properties of the standard OpenJPA <a href="../../../../org/apache/openjpa/conf/OpenJPAConfiguration.html" title="interface in org.apache.openjpa.conf"><code>OpenJPAConfiguration</code></a> can be |
| set by using their names and supplying a value.</li> |
| <li><i>-directory/-d <output directory></i>: Path to the base |
| source directory. The package structure will be created beneath |
| this directory if necessary. If not specified, the tool will try |
| to locate the .java file in the CLASSPATH and output to the same |
| directory; failing that, it will use the current directory as |
| the base directory. |
| <li><i>-ignoreErrors/-i <true/t | false/f></i>: If false, an |
| exception will be thrown if the tool encounters any class that |
| does not use application identity or uses the identity class of |
| its superclass; defaults to true.</li> |
| <li><i>-token/-t <token></i>: The token to use to separate |
| stingified primary key field values in the stringified oid.</li> |
| <li><i>-name/-n <id class name></i>: The name of the identity |
| class to generate. If this option is specified, you must only |
| give a single class argument. If the class metadata names an object |
| id class, this argument is ignored.</li> |
| <li><i>-suffix/-s <id class suffix></i>: A string to suffix each |
| persistent class with to create the identity class name. This is |
| overridden by <code>-name</code> or by any identity class name |
| specified in metadata.</li> |
| <li><i>-codeFormat/-cf.<property name> < property value></i> |
| : Arguments like this will be used to configure the bean |
| properties of the internal <a href="../../../../org/apache/openjpa/lib/util/CodeFormat.html" title="class in org.apache.openjpa.lib.util"><code>CodeFormat</code></a>.</li> |
| </ul> |
| Each additional argument can be either the full class name of the |
| type to create an id class for, the path to the .java file for the type, |
| the path to the .class file for the type, or the path to a .jdo file |
| listing one or more types. If a .java file already exists for an |
| application id, it will be backed up to a file named |
| <orig file name>~.</div> |
| <dl><dt><span class="strong">Throws:</span></dt> |
| <dd><code><a href="http://docs.oracle.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code></dd> |
| <dd><code><a href="http://docs.oracle.com/javase/6/docs/api/java/lang/ClassNotFoundException.html?is-external=true" title="class or interface in java.lang">ClassNotFoundException</a></code></dd></dl> |
| </li> |
| </ul> |
| <a name="run(org.apache.openjpa.conf.OpenJPAConfiguration, java.lang.String[], org.apache.openjpa.lib.util.Options)"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>run</h4> |
| <pre>public static boolean run(<a href="../../../../org/apache/openjpa/conf/OpenJPAConfiguration.html" title="interface in org.apache.openjpa.conf">OpenJPAConfiguration</a> conf, |
| <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>[] args, |
| <a href="../../../../org/apache/openjpa/lib/util/Options.html" title="class in org.apache.openjpa.lib.util">Options</a> opts) |
| throws <a href="http://docs.oracle.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a>, |
| <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/ClassNotFoundException.html?is-external=true" title="class or interface in java.lang">ClassNotFoundException</a></pre> |
| <div class="block">Run the application id tool with the given command-line and |
| given configuration. Returns false if invalid options were given.</div> |
| <dl><dt><span class="strong">Throws:</span></dt> |
| <dd><code><a href="http://docs.oracle.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code></dd> |
| <dd><code><a href="http://docs.oracle.com/javase/6/docs/api/java/lang/ClassNotFoundException.html?is-external=true" title="class or interface in java.lang">ClassNotFoundException</a></code></dd></dl> |
| </li> |
| </ul> |
| <a name="run(org.apache.openjpa.conf.OpenJPAConfiguration, java.lang.String[], org.apache.openjpa.enhance.ApplicationIdTool.Flags, java.lang.ClassLoader)"> |
| <!-- --> |
| </a> |
| <ul class="blockListLast"> |
| <li class="blockList"> |
| <h4>run</h4> |
| <pre>public static boolean run(<a href="../../../../org/apache/openjpa/conf/OpenJPAConfiguration.html" title="interface in org.apache.openjpa.conf">OpenJPAConfiguration</a> conf, |
| <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>[] args, |
| <a href="../../../../org/apache/openjpa/enhance/ApplicationIdTool.Flags.html" title="class in org.apache.openjpa.enhance">ApplicationIdTool.Flags</a> flags, |
| <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/ClassLoader.html?is-external=true" title="class or interface in java.lang">ClassLoader</a> loader) |
| throws <a href="http://docs.oracle.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a>, |
| <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/ClassNotFoundException.html?is-external=true" title="class or interface in java.lang">ClassNotFoundException</a></pre> |
| <div class="block">Run the tool. Returns false if invalid options were given.</div> |
| <dl><dt><span class="strong">Throws:</span></dt> |
| <dd><code><a href="http://docs.oracle.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code></dd> |
| <dd><code><a href="http://docs.oracle.com/javase/6/docs/api/java/lang/ClassNotFoundException.html?is-external=true" title="class or interface in java.lang">ClassNotFoundException</a></code></dd></dl> |
| </li> |
| </ul> |
| </li> |
| </ul> |
| </li> |
| </ul> |
| </div> |
| </div> |
| <!-- ========= END OF CLASS DATA ========= --> |
| <!-- ======= START OF BOTTOM NAVBAR ====== --> |
| <div class="bottomNav"><a name="navbar_bottom"> |
| <!-- --> |
| </a><a href="#skip-navbar_bottom" title="Skip navigation links"></a><a name="navbar_bottom_firstrow"> |
| <!-- --> |
| </a> |
| <ul class="navList" title="Navigation"> |
| <li><a href="../../../../overview-summary.html">Overview</a></li> |
| <li><a href="package-summary.html">Package</a></li> |
| <li class="navBarCell1Rev">Class</li> |
| <li><a href="class-use/ApplicationIdTool.html">Use</a></li> |
| <li><a href="package-tree.html">Tree</a></li> |
| <li><a href="../../../../deprecated-list.html">Deprecated</a></li> |
| <li><a href="../../../../index-all.html">Index</a></li> |
| <li><a href="../../../../help-doc.html">Help</a></li> |
| </ul> |
| </div> |
| <div class="subNav"> |
| <ul class="navList"> |
| <li>Prev Class</li> |
| <li><a href="../../../../org/apache/openjpa/enhance/ApplicationIdTool.Flags.html" title="class in org.apache.openjpa.enhance"><span class="strong">Next Class</span></a></li> |
| </ul> |
| <ul class="navList"> |
| <li><a href="../../../../index.html?org/apache/openjpa/enhance/ApplicationIdTool.html" target="_top">Frames</a></li> |
| <li><a href="ApplicationIdTool.html" target="_top">No Frames</a></li> |
| </ul> |
| <ul class="navList" id="allclasses_navbar_bottom"> |
| <li><a href="../../../../allclasses-noframe.html">All Classes</a></li> |
| </ul> |
| <div> |
| <script type="text/javascript"><!-- |
| allClassesLink = document.getElementById("allclasses_navbar_bottom"); |
| if(window==top) { |
| allClassesLink.style.display = "block"; |
| } |
| else { |
| allClassesLink.style.display = "none"; |
| } |
| //--> |
| </script> |
| </div> |
| <div> |
| <ul class="subNavList"> |
| <li>Summary: </li> |
| <li><a href="#nested_class_summary">Nested</a> | </li> |
| <li><a href="#field_summary">Field</a> | </li> |
| <li><a href="#constructor_summary">Constr</a> | </li> |
| <li><a href="#method_summary">Method</a></li> |
| </ul> |
| <ul class="subNavList"> |
| <li>Detail: </li> |
| <li><a href="#field_detail">Field</a> | </li> |
| <li><a href="#constructor_detail">Constr</a> | </li> |
| <li><a href="#method_detail">Method</a></li> |
| </ul> |
| </div> |
| <a name="skip-navbar_bottom"> |
| <!-- --> |
| </a></div> |
| <!-- ======== END OF BOTTOM NAVBAR ======= --> |
| <p class="legalCopy"><small>Copyright © 2006–2018 <a href="http://www.apache.org">Apache Software Foundation</a>. All rights reserved.</small></p> |
| </body> |
| </html> |