cmlenz 2003/06/11 09:16:42
Modified: integration/ant/src/test/org/apache/cactus/integration/ant
AntTestCase.java
integration/ant/src/test/org/apache/cactus/integration/ant/container
MockContainer.java MockHttpServer.java
Log:
Fix some "design for extension" violations
Revision Changes Path
1.8 +15 -15
jakarta-cactus/integration/ant/src/test/org/apache/cactus/integration/ant/AntTestCase.java
Index: AntTestCase.java
===================================================================
RCS file:
/home/cvs/jakarta-cactus/integration/ant/src/test/org/apache/cactus/integration/ant/AntTestCase.java,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -r1.7 -r1.8
--- AntTestCase.java 9 Jun 2003 19:50:09 -0000 1.7
+++ AntTestCase.java 11 Jun 2003 16:16:41 -0000 1.8
@@ -126,28 +126,28 @@
/**
* @see BuildListener#buildStarted
*/
- public void buildStarted(BuildEvent theEvent)
+ public final void buildStarted(BuildEvent theEvent)
{
}
/**
* @see BuildListener#buildFinished
*/
- public void buildFinished(BuildEvent theEvent)
+ public final void buildFinished(BuildEvent theEvent)
{
}
/**
* @see BuildListener#targetStarted
*/
- public void targetStarted(BuildEvent theEvent)
+ public final void targetStarted(BuildEvent theEvent)
{
}
/**
* @see BuildListener#targetFinished
*/
- public void targetFinished(BuildEvent theEvent)
+ public final void targetFinished(BuildEvent theEvent)
{
this.executedTargets.add(theEvent.getTarget().getName());
}
@@ -155,21 +155,21 @@
/**
* @see BuildListener#taskStarted
*/
- public void taskStarted(BuildEvent theEvent)
+ public final void taskStarted(BuildEvent theEvent)
{
}
/**
* @see BuildListener#taskFinished
*/
- public void taskFinished(BuildEvent theEvent)
+ public final void taskFinished(BuildEvent theEvent)
{
}
/**
* @see BuildListener#messageLogged
*/
- public void messageLogged(BuildEvent theEvent)
+ public final void messageLogged(BuildEvent theEvent)
{
StringBuffer buffer = (StringBuffer)
log.get(new Integer(theEvent.getPriority()));
@@ -230,7 +230,7 @@
* @param theLogLevel The log level of the message
* @throws IOException If an error occurred reading the log buffer
*/
- protected void assertMessageLogged(String theMessage, int theLogLevel)
+ protected final void assertMessageLogged(String theMessage, int theLogLevel)
throws IOException
{
StringBuffer buffer = (StringBuffer) log.get(new Integer(theLogLevel));
@@ -259,7 +259,7 @@
* @param theLogLevel The log level of the message
* @throws IOException If an error occurred reading the log buffer
*/
- protected void assertMessageLoggedContaining(String theSubstring,
+ protected final void assertMessageLoggedContaining(String theSubstring,
int theLogLevel)
throws IOException
{
@@ -286,7 +286,7 @@
*
* @param theName The name of the target
*/
- protected void assertTargetExecuted(String theName)
+ protected final void assertTargetExecuted(String theName)
{
assertTrue("Target '" + theName + "' should have been executed",
this.executedTargets.contains(theName));
@@ -296,7 +296,7 @@
* Executes the target in the project that corresponds to the current test
* case.
*/
- protected void executeTestTarget()
+ protected final void executeTestTarget()
{
this.project.executeTarget(getName());
}
@@ -306,7 +306,7 @@
*
* @return The project
*/
- protected Project getProject()
+ protected final Project getProject()
{
return this.project;
}
@@ -316,7 +316,7 @@
*
* @return The base directory
*/
- protected File getProjectDir()
+ protected final File getProjectDir()
{
return this.project.getBaseDir();
}
@@ -327,7 +327,7 @@
*
* @return The test target
*/
- protected Target getTestTarget()
+ protected final Target getTestTarget()
{
return (Target) getProject().getTargets().get(getName());
}
1.6 +2 -2
jakarta-cactus/integration/ant/src/test/org/apache/cactus/integration/ant/container/MockContainer.java
Index: MockContainer.java
===================================================================
RCS file:
/home/cvs/jakarta-cactus/integration/ant/src/test/org/apache/cactus/integration/ant/container/MockContainer.java,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -r1.5 -r1.6
--- MockContainer.java 14 May 2003 18:26:27 -0000 1.5
+++ MockContainer.java 11 Jun 2003 16:16:41 -0000 1.6
@@ -70,7 +70,7 @@
*
* @version $Id$
*/
-public class MockContainer implements Container
+public final class MockContainer implements Container
{
// Instance Variables ------------------------------------------------------
1.5 +2 -2
jakarta-cactus/integration/ant/src/test/org/apache/cactus/integration/ant/container/MockHttpServer.java
Index: MockHttpServer.java
===================================================================
RCS file:
/home/cvs/jakarta-cactus/integration/ant/src/test/org/apache/cactus/integration/ant/container/MockHttpServer.java,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -r1.4 -r1.5
--- MockHttpServer.java 9 Jun 2003 10:09:04 -0000 1.4
+++ MockHttpServer.java 11 Jun 2003 16:16:41 -0000 1.5
@@ -81,7 +81,7 @@
*
* @version $Id$
*/
-public class MockHttpServer implements Runnable
+public final class MockHttpServer implements Runnable
{
// Instance Variables ------------------------------------------------------
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]