vmassol 02/04/20 14:18:53
Modified: anttasks/src/java/org/apache/cactus/ant ResinRun.java
Log:
improved javadoc
Revision Changes Path
1.4 +19 -7
jakarta-cactus/anttasks/src/java/org/apache/cactus/ant/ResinRun.java
Index: ResinRun.java
===================================================================
RCS file:
/home/cvs/jakarta-cactus/anttasks/src/java/org/apache/cactus/ant/ResinRun.java,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- ResinRun.java 20 Apr 2002 19:46:27 -0000 1.3
+++ ResinRun.java 20 Apr 2002 21:18:53 -0000 1.4
@@ -66,7 +66,7 @@
* @author <a href="mailto:[EMAIL PROTECTED]">Vincent Massol</a>
* @author <a href="mailto:[EMAIL PROTECTED]">Robert Leftwich</a>
*
- * @version $Id: ResinRun.java,v 1.3 2002/04/20 19:46:27 vmassol Exp $
+ * @version $Id: ResinRun.java,v 1.4 2002/04/20 21:18:53 vmassol Exp $
* @see AbstractServerRun
*/
public class ResinRun extends AbstractServerRun
@@ -113,10 +113,10 @@
// Try Resin 2.0 first
try {
- startResin20(resinServer, resinClass);
+ startResin20(this.resinServer);
} catch (NoSuchMethodException nsme) {
// Try Resin 2.1
- startResin21(resinServer, resinClass);
+ startResin21(this.resinServer);
}
} catch (Exception e) {
@@ -125,19 +125,31 @@
}
}
- private void startResin20(Object resinServer, Class resinClass)
+ /**
+ * Starts Resin 2.0.x
+ *
+ * @param resinServer the <code>ResinServer</code> instance
+ * @throws Exception if an error happens when starting the server
+ */
+ private void startResin20(Object resinServer)
throws Exception
{
- Method initMethod = resinClass.getMethod("init",
+ Method initMethod = resinServer.getClass().getMethod("init",
new Class[]{boolean.class});
initMethod.invoke(resinServer, new Object[]{
new Boolean(true)});
}
- private void startResin21(Object resinServer, Class resinClass)
+ /**
+ * Starts Resin 2.1.x
+ *
+ * @param resinServer the <code>ResinServer</code> instance
+ * @throws Exception if an error happens when starting the server
+ */
+ private void startResin21(Object resinServer)
throws Exception
{
- Method initMethod = resinClass.getMethod("init",
+ Method initMethod = resinServer.getClass().getMethod("init",
new Class[]{ArrayList.class});
initMethod.invoke(resinServer, new Object[]{ null });
}
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>