<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <!--NewPage--> <HTML> <HEAD> <!-- Generated by javadoc (build 1.6.0_18) on Sat Dec 04 05:26:50 UTC 2010 --> <TITLE> org.apache.ws.jaxme.js.pattern </TITLE> <META NAME="date" CONTENT="2010-12-04"> <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../../stylesheet.css" TITLE="Style"> <SCRIPT type="text/javascript"> function windowTitle() { if (location.href.indexOf('is-external=true') == -1) { parent.document.title="org.apache.ws.jaxme.js.pattern"; } } </SCRIPT> <NOSCRIPT> </NOSCRIPT> </HEAD> <BODY BGCOLOR="white" onload="windowTitle();"> <HR> <!-- ========= START OF TOP NAVBAR ======= --> <A NAME="navbar_top"><!-- --></A> <A HREF="#skip-navbar_top" title="Skip navigation links"></A> <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY=""> <TR> <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A NAME="navbar_top_firstrow"><!-- --></A> <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY=""> <TR ALIGN="center" VALIGN="top"> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A> </TD> <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> <FONT CLASS="NavBarFont1Rev"><B>Package</B></FONT> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Class</FONT> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A> </TD> </TR> </TABLE> </TD> <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM> </EM> </TD> </TR> <TR> <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2"> <A HREF="../../../../../../org/apache/ws/jaxme/js/junit/xmlrpcclient/package-summary.html"><B>PREV PACKAGE</B></A> <A HREF="../../../../../../org/apache/ws/jaxme/js/util/package-summary.html"><B>NEXT PACKAGE</B></A></FONT></TD> <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2"> <A HREF="../../../../../../index.html?org/apache/ws/jaxme/js/pattern/package-summary.html" target="_top"><B>FRAMES</B></A> <A HREF="package-summary.html" target="_top"><B>NO FRAMES</B></A> <SCRIPT type="text/javascript"> <!-- if(window==top) { document.writeln('<A HREF="../../../../../../allclasses-noframe.html"><B>All Classes</B></A>'); } //--> </SCRIPT> <NOSCRIPT> <A HREF="../../../../../../allclasses-noframe.html"><B>All Classes</B></A> </NOSCRIPT> </FONT></TD> </TR> </TABLE> <A NAME="skip-navbar_top"></A> <!-- ========= END OF TOP NAVBAR ========= --> <HR> <H2> Package org.apache.ws.jaxme.js.pattern </H2> The pattern package <P> <B>See:</B> <BR> <A HREF="#package_description"><B>Description</B></A> <P> <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""> <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"> <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2"> <B>Interface Summary</B></FONT></TH> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD WIDTH="15%"><B><A HREF="../../../../../../org/apache/ws/jaxme/js/pattern/Reflector.html" title="interface in org.apache.ws.jaxme.js.pattern">Reflector</A></B></TD> <TD>The <code>Reflector</code> obtains informations on a certain class by converting it into an instance of <A HREF="../../../../../../org/apache/ws/jaxme/js/JavaSource.html" title="class in org.apache.ws.jaxme.js"><CODE>JavaSource</CODE></A>.</TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD WIDTH="15%"><B><A HREF="../../../../../../org/apache/ws/jaxme/js/pattern/VersionGenerator.ColumnUpdater.html" title="interface in org.apache.ws.jaxme.js.pattern">VersionGenerator.ColumnUpdater</A></B></TD> <TD>The ColumnUpdater is able to update one or more columns in a table.</TD> </TR> </TABLE> <P> <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""> <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"> <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2"> <B>Class Summary</B></FONT></TH> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD WIDTH="15%"><B><A HREF="../../../../../../org/apache/ws/jaxme/js/pattern/Ant.html" title="class in org.apache.ws.jaxme.js.pattern">Ant</A></B></TD> <TD>A set of Ant tasks for running the generators in the pattern package.</TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD WIDTH="15%"><B><A HREF="../../../../../../org/apache/ws/jaxme/js/pattern/Ant.AntChainGenerator.html" title="class in org.apache.ws.jaxme.js.pattern">Ant.AntChainGenerator</A></B></TD> <TD>Ant task for the <A HREF="../../../../../../org/apache/ws/jaxme/js/pattern/ChainGenerator.html" title="class in org.apache.ws.jaxme.js.pattern"><CODE>ChainGenerator</CODE></A>.</TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD WIDTH="15%"><B><A HREF="../../../../../../org/apache/ws/jaxme/js/pattern/Ant.AntProxyGenerator.html" title="class in org.apache.ws.jaxme.js.pattern">Ant.AntProxyGenerator</A></B></TD> <TD>The <code>AntProxyGenerator</code> is an Ant task providing access to the <A HREF="../../../../../../org/apache/ws/jaxme/js/pattern/ProxyGenerator.html" title="class in org.apache.ws.jaxme.js.pattern"><CODE>ProxyGenerator</CODE></A>.</TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD WIDTH="15%"><B><A HREF="../../../../../../org/apache/ws/jaxme/js/pattern/Ant.AntTypesafeEnumerationGenerator.html" title="class in org.apache.ws.jaxme.js.pattern">Ant.AntTypesafeEnumerationGenerator</A></B></TD> <TD>Ant task for generating typesafe enumerations.</TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD WIDTH="15%"><B><A HREF="../../../../../../org/apache/ws/jaxme/js/pattern/Ant.AntVersionGenerator.html" title="class in org.apache.ws.jaxme.js.pattern">Ant.AntVersionGenerator</A></B></TD> <TD>Ant task for the <A HREF="../../../../../../org/apache/ws/jaxme/js/pattern/VersionGenerator.html" title="class in org.apache.ws.jaxme.js.pattern"><CODE>VersionGenerator</CODE></A></TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD WIDTH="15%"><B><A HREF="../../../../../../org/apache/ws/jaxme/js/pattern/Ant.BasicAntTask.html" title="class in org.apache.ws.jaxme.js.pattern">Ant.BasicAntTask</A></B></TD> <TD> </TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD WIDTH="15%"><B><A HREF="../../../../../../org/apache/ws/jaxme/js/pattern/Ant.ReallyBasicAntTask.html" title="class in org.apache.ws.jaxme.js.pattern">Ant.ReallyBasicAntTask</A></B></TD> <TD> </TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD WIDTH="15%"><B><A HREF="../../../../../../org/apache/ws/jaxme/js/pattern/Ant.XmlRpcGenerator.html" title="class in org.apache.ws.jaxme.js.pattern">Ant.XmlRpcGenerator</A></B></TD> <TD>An ant task for the <A HREF="../../../../../../org/apache/ws/jaxme/js/apps/XmlRpcClientGenerator.html" title="class in org.apache.ws.jaxme.js.apps"><CODE>XmlRpcClientGenerator</CODE></A>.</TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD WIDTH="15%"><B><A HREF="../../../../../../org/apache/ws/jaxme/js/pattern/Ant.XmlRpcGenerator.Dispatcher.html" title="class in org.apache.ws.jaxme.js.pattern">Ant.XmlRpcGenerator.Dispatcher</A></B></TD> <TD>The nested child element "dispatcher".</TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD WIDTH="15%"><B><A HREF="../../../../../../org/apache/ws/jaxme/js/pattern/ChainGenerator.html" title="class in org.apache.ws.jaxme.js.pattern">ChainGenerator</A></B></TD> <TD>This class generates so-called event chains.</TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD WIDTH="15%"><B><A HREF="../../../../../../org/apache/ws/jaxme/js/pattern/CompiledClassReflector.html" title="class in org.apache.ws.jaxme.js.pattern">CompiledClassReflector</A></B></TD> <TD>Reflector for gathering information on a compiled class.</TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD WIDTH="15%"><B><A HREF="../../../../../../org/apache/ws/jaxme/js/pattern/InterfaceDescription.html" title="class in org.apache.ws.jaxme.js.pattern">InterfaceDescription</A></B></TD> <TD>The <code>InterfaceDescription</code> is used by the <A HREF="../../../../../../org/apache/ws/jaxme/js/pattern/ProxyGenerator.html" title="class in org.apache.ws.jaxme.js.pattern"><CODE>ProxyGenerator</CODE></A> as information storage about the interfaces being implemented.<br> The main purporse of an intermediate class is to encapsulate the way, how information about these classes is gathered: If the interface being implemented is a compiled class, then Java reflection is used. Otherwise, if the interface being implemented is present as a Java source file, then the <A HREF="../../../../../../org/apache/ws/jaxme/js/util/JavaParser.html" title="class in org.apache.ws.jaxme.js.util"><CODE>JavaParser</CODE></A> is used. </ol</TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD WIDTH="15%"><B><A HREF="../../../../../../org/apache/ws/jaxme/js/pattern/MethodKey.html" title="class in org.apache.ws.jaxme.js.pattern">MethodKey</A></B></TD> <TD>This class is a key for generated methods.</TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD WIDTH="15%"><B><A HREF="../../../../../../org/apache/ws/jaxme/js/pattern/ProxyGenerator.html" title="class in org.apache.ws.jaxme.js.pattern">ProxyGenerator</A></B></TD> <TD>This class is a generator for the proxy object pattern.</TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD WIDTH="15%"><B><A HREF="../../../../../../org/apache/ws/jaxme/js/pattern/SourceReflector.html" title="class in org.apache.ws.jaxme.js.pattern">SourceReflector</A></B></TD> <TD>Reflector for gathering information about a Java source file.</TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD WIDTH="15%"><B><A HREF="../../../../../../org/apache/ws/jaxme/js/pattern/TypesafeEnumerationGenerator.html" title="class in org.apache.ws.jaxme.js.pattern">TypesafeEnumerationGenerator</A></B></TD> <TD>This class is a generator for the typesafe enumeration pattern.</TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD WIDTH="15%"><B><A HREF="../../../../../../org/apache/ws/jaxme/js/pattern/TypesafeEnumerationGenerator.Item.html" title="class in org.apache.ws.jaxme.js.pattern">TypesafeEnumerationGenerator.Item</A></B></TD> <TD> </TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD WIDTH="15%"><B><A HREF="../../../../../../org/apache/ws/jaxme/js/pattern/VersionGenerator.html" title="class in org.apache.ws.jaxme.js.pattern">VersionGenerator</A></B></TD> <TD>The VersionGenerator is able to clone a version of a row in a database.</TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD WIDTH="15%"><B><A HREF="../../../../../../org/apache/ws/jaxme/js/pattern/VersionGenerator.TableInfo.html" title="class in org.apache.ws.jaxme.js.pattern">VersionGenerator.TableInfo</A></B></TD> <TD>This class is used internally to maintain the informations on the tables being cloned.</TD> </TR> </TABLE> <P> <A NAME="package_description"><!-- --></A><H2> Package org.apache.ws.jaxme.js.pattern Description </H2> <P> <h1>The pattern package</h1> <p>This package contains a set of design patterns implemented with the JaxMe JavaSource generator framework. It is provided both for demonstration and actual use. Each pattern is accompanied with a corresponding Ant task that allows to invoke the respective generator from within an Ant build script. The patterns are:</p> <table border="1"> <tr><th>Design pattern(s)</th><th>Class</th><th>Ant task</th><th>Description</th></tr> <tr> <td>Proxy objects<br>Multiple inheritance</td> <td><A HREF="../../../../../../org/apache/ws/jaxme/js/pattern/ProxyGenerator.html" title="class in org.apache.ws.jaxme.js.pattern"><CODE>ProxyGenerator</CODE></A></td> <td>proxyGenerator</td> <td>Proxy are instances that delegate most or all method calls to another object. Proxy objects in Java are typically created by the class <CODE>Proxy</CODE>. Compared to this class, the generator has the advantage, that it is much easier to adapt the proxy object to your own needs: In our case you simple subclass the generated Proxy class.<br> Proxy objects can also be used to implement something like multiple inheritance. This is demonstrated in the Unit test <A HREF="../../../../../../org/apache/ws/jaxme/js/junit/MultipleInheritanceTest.html" title="class in org.apache.ws.jaxme.js.junit"><CODE>MultipleInheritanceTest</CODE></A>, where a subclass of <CODE>Observable</CODE> is created, that is also an instance of <CODE>List</CODE> by inheriting from <CODE>ArrayList</CODE>.</td> </tr> <tr> <td>Typesafe enumerations</td> <td><A HREF="../../../../../../org/apache/ws/jaxme/js/pattern/TypesafeEnumerationGenerator.html" title="class in org.apache.ws.jaxme.js.pattern"><CODE>TypesafeEnumerationGenerator</CODE></A></td> <td>enumGenerator</td> <td>A typesafe enumeration is a Java class that guarantees that only a specified set of instances can exist. These instances are part of the class and accessible through public, static, final fields.</td> </tr> <tr> <td>Proxy chains</td> <td><A HREF="../../../../../../org/apache/ws/jaxme/js/pattern/ChainGenerator.html" title="class in org.apache.ws.jaxme.js.pattern"><CODE>ChainGenerator</CODE></A></td> <td>chainGenerator</td> <td>A proxy chain can be viewed as a set of event handlers implementing a common interface. The interface methods are the events being processed. Each element in the chain can decide to process an event alone (by returning immediately), to delegate the event to the next element in the chain (by calling the interface method in its superclass) or to post process the result of the delegated event.</td> </tr> </table> <P> <P> <DL> </DL> <HR> <!-- ======= START OF BOTTOM NAVBAR ====== --> <A NAME="navbar_bottom"><!-- --></A> <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A> <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY=""> <TR> <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A NAME="navbar_bottom_firstrow"><!-- --></A> <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY=""> <TR ALIGN="center" VALIGN="top"> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A> </TD> <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> <FONT CLASS="NavBarFont1Rev"><B>Package</B></FONT> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Class</FONT> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A> </TD> </TR> </TABLE> </TD> <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM> </EM> </TD> </TR> <TR> <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2"> <A HREF="../../../../../../org/apache/ws/jaxme/js/junit/xmlrpcclient/package-summary.html"><B>PREV PACKAGE</B></A> <A HREF="../../../../../../org/apache/ws/jaxme/js/util/package-summary.html"><B>NEXT PACKAGE</B></A></FONT></TD> <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2"> <A HREF="../../../../../../index.html?org/apache/ws/jaxme/js/pattern/package-summary.html" target="_top"><B>FRAMES</B></A> <A HREF="package-summary.html" target="_top"><B>NO FRAMES</B></A> <SCRIPT type="text/javascript"> <!-- if(window==top) { document.writeln('<A HREF="../../../../../../allclasses-noframe.html"><B>All Classes</B></A>'); } //--> </SCRIPT> <NOSCRIPT> <A HREF="../../../../../../allclasses-noframe.html"><B>All Classes</B></A> </NOSCRIPT> </FONT></TD> </TR> </TABLE> <A NAME="skip-navbar_bottom"></A> <!-- ======== END OF BOTTOM NAVBAR ======= --> <HR> </BODY> </HTML>