clirr-devel Mailing List for Clirr (Page 41)
Status: Alpha
Brought to you by:
lkuehne
You can subscribe to this list here.
| 2003 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
(15) |
Oct
(23) |
Nov
|
Dec
(25) |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2004 |
Jan
(9) |
Feb
|
Mar
|
Apr
|
May
(76) |
Jun
(207) |
Jul
(242) |
Aug
(42) |
Sep
(33) |
Oct
|
Nov
(7) |
Dec
(1) |
| 2005 |
Jan
|
Feb
|
Mar
(5) |
Apr
|
May
|
Jun
|
Jul
(3) |
Aug
(66) |
Sep
(38) |
Oct
(6) |
Nov
|
Dec
(2) |
| 2006 |
Jan
(17) |
Feb
(5) |
Mar
(28) |
Apr
(6) |
May
|
Jun
|
Jul
(1) |
Aug
|
Sep
|
Oct
(1) |
Nov
(1) |
Dec
(7) |
| 2007 |
Jan
|
Feb
|
Mar
|
Apr
(7) |
May
(33) |
Jun
(4) |
Jul
(3) |
Aug
|
Sep
(5) |
Oct
|
Nov
|
Dec
|
| 2008 |
Jan
(4) |
Feb
(3) |
Mar
(2) |
Apr
|
May
(1) |
Jun
|
Jul
(6) |
Aug
(8) |
Sep
(5) |
Oct
(20) |
Nov
(7) |
Dec
(9) |
| 2009 |
Jan
(8) |
Feb
(3) |
Mar
(20) |
Apr
(10) |
May
(40) |
Jun
(11) |
Jul
(23) |
Aug
(4) |
Sep
(1) |
Oct
(1) |
Nov
|
Dec
(2) |
| 2010 |
Jan
(5) |
Feb
(1) |
Mar
|
Apr
|
May
|
Jun
(1) |
Jul
|
Aug
(2) |
Sep
|
Oct
|
Nov
|
Dec
|
| 2011 |
Jan
|
Feb
|
Mar
|
Apr
(3) |
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
(1) |
| 2012 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
(1) |
Sep
|
Oct
|
Nov
|
Dec
|
| 2013 |
Jan
|
Feb
|
Mar
|
Apr
(6) |
May
(22) |
Jun
(2) |
Jul
|
Aug
|
Sep
|
Oct
(2) |
Nov
(1) |
Dec
(2) |
| 2014 |
Jan
(5) |
Feb
|
Mar
|
Apr
|
May
(1) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
(1) |
Dec
|
| 2015 |
Jan
(1) |
Feb
(2) |
Mar
(1) |
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| 2016 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(1) |
Nov
|
Dec
|
| 2017 |
Jan
|
Feb
|
Mar
(1) |
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
|
From: Lars K?h. <lk...@us...> - 2003-12-31 09:45:49
|
Update of /cvsroot/clirr/clirr/src/test/net/sf/clirr/checks
In directory sc8-pr-cvs1:/tmp/cvs-serv17744/src/test/net/sf/clirr/checks
Modified Files:
TestDiffListener.java
Log Message:
improved failure message
Index: TestDiffListener.java
===================================================================
RCS file: /cvsroot/clirr/clirr/src/test/net/sf/clirr/checks/TestDiffListener.java,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- TestDiffListener.java 27 Dec 2003 17:45:30 -0000 1.2
+++ TestDiffListener.java 31 Dec 2003 09:45:45 -0000 1.3
@@ -27,7 +27,7 @@
for (Iterator it = expectedDiffs.iterator(); it.hasNext();) {
ApiDifference apiDifference = (ApiDifference) it.next();
- TestCase.assertTrue("expected diff " + apiDifference + " was not generated",
+ TestCase.assertTrue("expected diff " + apiDifference + " was not generated: " + diffs,
diffs.contains(apiDifference));
}
|
|
From: Lars K?h. <lk...@us...> - 2003-12-28 15:43:43
|
Update of /cvsroot/clirr/clirr/src/java/net/sf/clirr/checks
In directory sc8-pr-cvs1:/tmp/cvs-serv11499/src/java/net/sf/clirr/checks
Modified Files:
RemovedClassCheck.java
Log Message:
simplified inheritance hierarchy
Index: RemovedClassCheck.java
===================================================================
RCS file: /cvsroot/clirr/clirr/src/java/net/sf/clirr/checks/RemovedClassCheck.java,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -r1.6 -r1.7
--- RemovedClassCheck.java 27 Sep 2003 05:28:43 -0000 1.6
+++ RemovedClassCheck.java 28 Dec 2003 15:43:40 -0000 1.7
@@ -21,7 +21,6 @@
import net.sf.clirr.event.Severity;
import net.sf.clirr.framework.ApiDiffDispatcher;
-import net.sf.clirr.framework.ClassSetChangeCheck;
import org.apache.bcel.util.ClassSet;
/**
@@ -31,7 +30,6 @@
*/
public final class RemovedClassCheck
extends AbstractClassSetChangeCheck
- implements ClassSetChangeCheck
{
/**
* Create a new instance of this check.
|
|
From: Lars K?h. <lk...@us...> - 2003-12-28 15:43:29
|
Update of /cvsroot/clirr/clirr/src/java/net/sf/clirr/checks
In directory sc8-pr-cvs1:/tmp/cvs-serv11446/src/java/net/sf/clirr/checks
Modified Files:
AddedClassCheck.java
Log Message:
simplified inheritance hierarchy
Index: AddedClassCheck.java
===================================================================
RCS file: /cvsroot/clirr/clirr/src/java/net/sf/clirr/checks/AddedClassCheck.java,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -r1.5 -r1.6
--- AddedClassCheck.java 27 Sep 2003 05:28:43 -0000 1.5
+++ AddedClassCheck.java 28 Dec 2003 15:43:26 -0000 1.6
@@ -21,7 +21,6 @@
import net.sf.clirr.event.Severity;
import net.sf.clirr.framework.ApiDiffDispatcher;
-import net.sf.clirr.framework.ClassSetChangeCheck;
import org.apache.bcel.util.ClassSet;
/**
@@ -31,7 +30,6 @@
*/
public final class AddedClassCheck
extends AbstractClassSetChangeCheck
- implements ClassSetChangeCheck
{
/**
* Create a new instance of this check.
|
|
From: Lars K?h. <lk...@us...> - 2003-12-28 15:43:16
|
Update of /cvsroot/clirr/clirr/src/java/net/sf/clirr/checks
In directory sc8-pr-cvs1:/tmp/cvs-serv11409/src/java/net/sf/clirr/checks
Modified Files:
AbstractClassSetChangeCheck.java
Log Message:
simplified inheritance hierarchy
Index: AbstractClassSetChangeCheck.java
===================================================================
RCS file: /cvsroot/clirr/clirr/src/java/net/sf/clirr/checks/AbstractClassSetChangeCheck.java,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -r1.7 -r1.8
--- AbstractClassSetChangeCheck.java 27 Dec 2003 19:08:42 -0000 1.7
+++ AbstractClassSetChangeCheck.java 28 Dec 2003 15:43:12 -0000 1.8
@@ -24,9 +24,10 @@
import net.sf.clirr.event.Severity;
import net.sf.clirr.framework.AbstractDiffReporter;
import net.sf.clirr.framework.ApiDiffDispatcher;
+import net.sf.clirr.framework.ClassSetChangeCheck;
abstract class AbstractClassSetChangeCheck
- extends AbstractDiffReporter
+ extends AbstractDiffReporter implements ClassSetChangeCheck
{
protected AbstractClassSetChangeCheck(ApiDiffDispatcher dispatcher)
{
|
|
From: Lars K?h. <lk...@us...> - 2003-12-28 09:42:52
|
Update of /cvsroot/clirr/clirr/xdocs
In directory sc8-pr-cvs1:/tmp/cvs-serv19185/xdocs
Modified Files:
index.xml
Log Message:
fixed spelling
Index: index.xml
===================================================================
RCS file: /cvsroot/clirr/clirr/xdocs/index.xml,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- index.xml 15 Sep 2003 05:57:50 -0000 1.2
+++ index.xml 28 Dec 2003 09:42:48 -0000 1.3
@@ -8,10 +8,10 @@
<section name="What is it?">
<p>
Clirr is a tool that checks Java libraries for binary compatibility
-with older releases. Basically you give it two
+with older releases. Basically you give it two
sets of jar files and Clirr dumps out a list of changes in the public api.
The Clirr Ant task can be configured to break the build if it detects
-incompatible api changes. In a continuos integration process Clirr can
+incompatible api changes. In a continuous integration process Clirr can
automatically prevent accidental introduction of binary compatibility
problems.
</p>
|
|
From: Lars K?h. <lk...@us...> - 2003-12-28 09:39:54
|
Update of /cvsroot/clirr/clirr/src/java/net/sf/clirr/event
In directory sc8-pr-cvs1:/tmp/cvs-serv18755/src/java/net/sf/clirr/event
Modified Files:
ApiDifference.java XmlDiffListener.java
Log Message:
fixed checkstyle "line too long" and "trailing whitespace" errors
Index: ApiDifference.java
===================================================================
RCS file: /cvsroot/clirr/clirr/src/java/net/sf/clirr/event/ApiDifference.java,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -r1.5 -r1.6
--- ApiDifference.java 27 Dec 2003 19:08:42 -0000 1.5
+++ ApiDifference.java 28 Dec 2003 09:39:47 -0000 1.6
@@ -22,7 +22,7 @@
/**
* Describes an API change.
- *
+ *
* @author Lars
*/
public final class ApiDifference
@@ -67,7 +67,7 @@
/**
* Create a new API differnce representation.
- *
+ *
* @param report a human readable string describing the change that was made.
* @param severity the severity in terms of binary API compatibility.
*/
@@ -85,7 +85,7 @@
* definately break, WARNING means that clients may break, depending
* on how they use the library. See the eclipse paper for further
* explanation.
- *
+ *
* @return the severity of the API difference.
*/
public Severity getSeverity()
@@ -95,7 +95,7 @@
/**
* Human readable api change description.
- *
+ *
* @return a human readable description of this API difference.
*/
public String getReport()
@@ -147,19 +147,26 @@
{
return false;
}
+
if (severity != null ? !severity.equals(other.severity) : other.severity != null)
{
return false;
}
- if (affectedClass != null ? !affectedClass.equals(other.affectedClass) : other.affectedClass != null)
+
+ final String otherClass = other.affectedClass;
+ if (affectedClass != null ? !affectedClass.equals(otherClass) : otherClass != null)
{
return false;
}
- if (affectedMethod != null ? !affectedMethod.equals(other.affectedMethod) : other.affectedMethod != null)
+
+ final String otherMethod = other.affectedMethod;
+ if (affectedMethod != null ? !affectedMethod.equals(otherMethod) : otherMethod != null)
{
return false;
}
- if (affectedField != null ? !affectedField.equals(other.affectedField) : other.affectedField != null)
+
+ final String otherField = other.affectedField;
+ if (affectedField != null ? !affectedField.equals(otherField) : otherField != null)
{
return false;
}
Index: XmlDiffListener.java
===================================================================
RCS file: /cvsroot/clirr/clirr/src/java/net/sf/clirr/event/XmlDiffListener.java,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -r1.6 -r1.7
--- XmlDiffListener.java 27 Dec 2003 19:08:42 -0000 1.6
+++ XmlDiffListener.java 28 Dec 2003 09:39:47 -0000 1.7
@@ -26,7 +26,7 @@
* A DiffListener that reports any detected difference to
* an XML file. That file can be used by subsequent processing steps
* to create nice looking reports in HTML, PDF, etc.
- *
+ *
* @author lkuehne
*/
public final class XmlDiffListener extends FileDiffListener
@@ -59,7 +59,7 @@
/**
* Writes an XML header and toplevel tag to the xml stream.
- *
+ *
* @see DiffListener#start()
*/
public void start()
@@ -80,7 +80,7 @@
/**
* Closes the toplevel tag that was opened in start.
- *
+ *
* @see DiffListener#stop()
*/
protected void writeFooter()
|
|
From: Lars K?h. <lk...@us...> - 2003-12-28 09:39:53
|
Update of /cvsroot/clirr/clirr/src/java/net/sf/clirr
In directory sc8-pr-cvs1:/tmp/cvs-serv18755/src/java/net/sf/clirr
Modified Files:
Checker.java
Log Message:
fixed checkstyle "line too long" and "trailing whitespace" errors
Index: Checker.java
===================================================================
RCS file: /cvsroot/clirr/clirr/src/java/net/sf/clirr/Checker.java,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -r1.6 -r1.7
--- Checker.java 27 Dec 2003 17:47:16 -0000 1.6
+++ Checker.java 28 Dec 2003 09:39:48 -0000 1.7
@@ -224,7 +224,8 @@
}
catch (MalformedURLException ex)
{
- final IllegalArgumentException illegalArgumentException = new IllegalArgumentException("Cannot create classloader with jar file " + jarFile);
+ final IllegalArgumentException illegalArgumentException =
+ new IllegalArgumentException("Cannot create classloader with jar file " + jarFile);
illegalArgumentException.initCause(ex);
throw illegalArgumentException;
}
|
|
From: Lars K?h. <lk...@us...> - 2003-12-28 09:37:54
|
Update of /cvsroot/clirr/clirr/src/java/net/sf/clirr/framework
In directory sc8-pr-cvs1:/tmp/cvs-serv18522/src/java/net/sf/clirr/framework
Modified Files:
AbstractDiffReporter.java
Log Message:
import cleanup
Index: AbstractDiffReporter.java
===================================================================
RCS file: /cvsroot/clirr/clirr/src/java/net/sf/clirr/framework/AbstractDiffReporter.java,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- AbstractDiffReporter.java 27 Dec 2003 19:08:42 -0000 1.3
+++ AbstractDiffReporter.java 28 Dec 2003 09:37:49 -0000 1.4
@@ -21,9 +21,8 @@
import net.sf.clirr.event.ApiDifference;
import net.sf.clirr.event.Severity;
-import org.apache.bcel.classfile.JavaClass;
-import org.apache.bcel.classfile.Method;
import org.apache.bcel.classfile.Field;
+import org.apache.bcel.classfile.Method;
public abstract class AbstractDiffReporter
{
|
|
From: Lars K?h. <lk...@us...> - 2003-12-28 09:07:45
|
Update of /cvsroot/clirr/clirr/xdocs
In directory sc8-pr-cvs1:/tmp/cvs-serv15161/xdocs
Modified Files:
related.xml download.xml
Log Message:
fixed maven links
Index: related.xml
===================================================================
RCS file: /cvsroot/clirr/clirr/xdocs/related.xml,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- related.xml 20 Sep 2003 12:59:49 -0000 1.1
+++ related.xml 28 Dec 2003 09:07:42 -0000 1.2
@@ -21,13 +21,14 @@
</li>
<li>
In the near future there will probably be a
- <a href="maven.apache.org">Maven</a> plugin for Clirr.
+ <a href="http://maven.apache.org">Maven</a> plugin for Clirr.
Stay tuned.
</li>
<li>
If you like Clirr because you want to deliver quality work
to your users, you might want to have a look at
- <a href="http://checkstyle.sf.net">Checkstyle</a>.
+ <a href="http://checkstyle.sf.net">Checkstyle</a>, a tool
+ for automatic code inspection.
The development teams of Clirr and Checkstyle overlap,
so if you like Clirr, you will probably love Checkstyle.
</li>
Index: download.xml
===================================================================
RCS file: /cvsroot/clirr/clirr/xdocs/download.xml,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- download.xml 29 Sep 2003 05:22:33 -0000 1.2
+++ download.xml 28 Dec 2003 09:07:42 -0000 1.3
@@ -34,7 +34,7 @@
<ul>
<li>
the latest release of <a
- href="maven.apache.org">Maven</a>, at the time of
+ href="http://maven.apache.org">Maven</a>, at the time of
writing that's beta-10.
</li>
<li>
|
|
From: Lars K?h. <lk...@us...> - 2003-12-28 05:16:46
|
Update of /cvsroot/clirr/clirr/src/test/net/sf/clirr/ant
In directory sc8-pr-cvs1:/tmp/cvs-serv6028/src/test/net/sf/clirr/ant
Modified Files:
ChangeCounterTest.java
Log Message:
added information about affected class/method/field to ApiDifference
This is a first step towards filtering diffs to let the user specify changes that are OK
Index: ChangeCounterTest.java
===================================================================
RCS file: /cvsroot/clirr/clirr/src/test/net/sf/clirr/ant/ChangeCounterTest.java,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- ChangeCounterTest.java 27 Dec 2003 17:44:17 -0000 1.2
+++ ChangeCounterTest.java 27 Dec 2003 19:08:42 -0000 1.3
@@ -9,12 +9,12 @@
public void testCorrectCounting()
{
ChangeCounter counter = new ChangeCounter();
- counter.reportDiff(new ApiDifference("blah", Severity.WARNING));
- counter.reportDiff(new ApiDifference("blah", Severity.ERROR));
- counter.reportDiff(new ApiDifference("blah", Severity.INFO));
- counter.reportDiff(new ApiDifference("blah", Severity.ERROR));
- counter.reportDiff(new ApiDifference("blah", Severity.ERROR));
- counter.reportDiff(new ApiDifference("blah", Severity.WARNING));
+ counter.reportDiff(new ApiDifference("blah", Severity.WARNING, "Test", null, null));
+ counter.reportDiff(new ApiDifference("blah", Severity.ERROR, "Test", null, null));
+ counter.reportDiff(new ApiDifference("blah", Severity.INFO, "Test", null, null));
+ counter.reportDiff(new ApiDifference("blah", Severity.ERROR, "Test", null, null));
+ counter.reportDiff(new ApiDifference("blah", Severity.ERROR, "Test", null, null));
+ counter.reportDiff(new ApiDifference("blah", Severity.WARNING, "Test", null, null));
assertEquals("number of expected errors", 3, counter.getErrors());
assertEquals("number of expected warnings", 2, counter.getWarnings());
assertEquals("number of expected infos", 1, counter.getInfos());
|
|
From: Lars K?h. <lk...@us...> - 2003-12-28 05:02:04
|
Update of /cvsroot/clirr/clirr/src/test/net/sf/clirr/checks
In directory sc8-pr-cvs1:/tmp/cvs-serv6028/src/test/net/sf/clirr/checks
Modified Files:
GenderChangeCheckTest.java
Log Message:
added information about affected class/method/field to ApiDifference
This is a first step towards filtering diffs to let the user specify changes that are OK
Index: GenderChangeCheckTest.java
===================================================================
RCS file: /cvsroot/clirr/clirr/src/test/net/sf/clirr/checks/GenderChangeCheckTest.java,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- GenderChangeCheckTest.java 5 Oct 2003 17:54:35 -0000 1.1
+++ GenderChangeCheckTest.java 27 Dec 2003 19:08:42 -0000 1.2
@@ -9,8 +9,8 @@
public void testGenderChangeCheckTest()
{
ApiDifference[] expected = new ApiDifference[] {
- new ApiDifference("Changed Gender of testlib.ClassBecomesInterface", Severity.ERROR),
- new ApiDifference("Changed Gender of testlib.InterfaceBecomesClass", Severity.ERROR),
+ new ApiDifference("Changed Gender of testlib.ClassBecomesInterface", Severity.ERROR, "testlib.ClassBecomesInterface", null, null),
+ new ApiDifference("Changed Gender of testlib.InterfaceBecomesClass", Severity.ERROR, "testlib.InterfaceBecomesClass", null, null),
};
verify(expected);
}
|
|
From: Lars K?h. <lk...@us...> - 2003-12-28 05:00:06
|
Update of /cvsroot/clirr/clirr/src/java/net/sf/clirr/framework
In directory sc8-pr-cvs1:/tmp/cvs-serv6028/src/java/net/sf/clirr/framework
Modified Files:
AbstractDiffReporter.java
Log Message:
added information about affected class/method/field to ApiDifference
This is a first step towards filtering diffs to let the user specify changes that are OK
Index: AbstractDiffReporter.java
===================================================================
RCS file: /cvsroot/clirr/clirr/src/java/net/sf/clirr/framework/AbstractDiffReporter.java,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- AbstractDiffReporter.java 27 Sep 2003 05:28:43 -0000 1.2
+++ AbstractDiffReporter.java 27 Dec 2003 19:08:42 -0000 1.3
@@ -21,6 +21,9 @@
import net.sf.clirr.event.ApiDifference;
import net.sf.clirr.event.Severity;
+import org.apache.bcel.classfile.JavaClass;
+import org.apache.bcel.classfile.Method;
+import org.apache.bcel.classfile.Field;
public abstract class AbstractDiffReporter
{
@@ -37,8 +40,9 @@
return dispatcher;
}
- protected final void log(String msg, Severity severity)
+ protected final void log(String msg, Severity severity, String clazz, Method method, Field field)
{
- getApiDiffDispatcher().fireDiff(new ApiDifference(msg, severity));
+ final ApiDifference diff = new ApiDifference(msg, severity, clazz, null, null);
+ getApiDiffDispatcher().fireDiff(diff);
}
}
|
|
From: Lars K?h. <lk...@us...> - 2003-12-27 19:22:03
|
Update of /cvsroot/clirr/clirr/src/java/net/sf/clirr/ant
In directory sc8-pr-cvs1:/tmp/cvs-serv5641/src/java/net/sf/clirr/ant
Modified Files:
AntTask.java
Log Message:
fixed some findings of IDEA InspectionGadgets plugin
Index: AntTask.java
===================================================================
RCS file: /cvsroot/clirr/clirr/src/java/net/sf/clirr/ant/AntTask.java,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -r1.5 -r1.6
--- AntTask.java 29 Sep 2003 05:26:12 -0000 1.5
+++ AntTask.java 27 Dec 2003 19:05:34 -0000 1.6
@@ -203,7 +203,7 @@
final String type = formatter.getType();
final String outFile = formatter.getOutFile();
- formattersWriteToStdOut = formattersWriteToStdOut || (outFile == null);
+ formattersWriteToStdOut = formattersWriteToStdOut || outFile == null;
try
{
@@ -250,9 +250,12 @@
URL url = entry.toURL();
cpUrls[i] = url;
}
- catch (MalformedURLException e)
+ catch (MalformedURLException ex)
{
- throw new RuntimeException("Cannot create classLoader from classpath entry " + entry);
+ final IllegalArgumentException illegalArgEx = new IllegalArgumentException(
+ "Cannot create classLoader from classpath entry " + entry);
+ illegalArgEx.initCause(ex);
+ throw illegalArgEx;
}
}
final URLClassLoader classPathLoader = new URLClassLoader(cpUrls);
|
|
From: Lars K?h. <lk...@us...> - 2003-12-27 19:15:26
|
Update of /cvsroot/clirr/clirr/src/java/net/sf/clirr/event
In directory sc8-pr-cvs1:/tmp/cvs-serv6028/src/java/net/sf/clirr/event
Modified Files:
ApiDifference.java FileDiffListener.java XmlDiffListener.java
Log Message:
added information about affected class/method/field to ApiDifference
This is a first step towards filtering diffs to let the user specify changes that are OK
Index: ApiDifference.java
===================================================================
RCS file: /cvsroot/clirr/clirr/src/java/net/sf/clirr/event/ApiDifference.java,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -r1.4 -r1.5
--- ApiDifference.java 5 Oct 2003 17:56:31 -0000 1.4
+++ ApiDifference.java 27 Dec 2003 19:08:42 -0000 1.5
@@ -21,32 +21,63 @@
/**
- * TODO: Add structure.
- * E.g.
- * - origfile, newfile
- * - Class-/MethodName
+ * Describes an API change.
+ *
* @author Lars
*/
public final class ApiDifference
{
+ private static final int HASHCODE_MAGIC = 29;
+ /** human readable change report. */
private String report;
+ /** severity of the change, as determined by clirr. */
private Severity severity;
- //private boolean expected;
+ /** The fully qualified class name that is affected by the API change. */
+ private String affectedClass;
+
+ /**
+ * The method that is affected, if any.
+ * <p/>
+ * The content is the method name plus the fully qualified
+ * parameter types separated by comma and space and enclosed in
+ * brackets, e.g. "doStuff(java.lang.String, int)".
+ * <p/>
+ * This value is <code>null</code> if no single method is
+ * affected, i.e. if the
+ * api change affects a field or is global
+ * (like "class is now final").
+ */
+ private String affectedMethod;
+
+ /**
+ * The field that is affected, if any.
+ * <p/>
+ * The content is the field name, e.g. "someValue".
+ * Type information for the field is not available.
+ * <p/>
+ * This value is <code>null</code> if no single field is
+ * affected, i.e. if the
+ * api change affects a method or is global
+ * (like "class is now final").
+ */
+ private String affectedField;
/**
* Create a new API differnce representation.
- *
- * @param report a human readable string describing the change that was made.
+ *
+ * @param report a human readable string describing the change that was made.
* @param severity the severity in terms of binary API compatibility.
*/
- public ApiDifference(String report, Severity severity /*, boolean expected*/)
+ public ApiDifference(String report, Severity severity, String clazz, String method, String field)
{
this.report = report;
this.severity = severity;
-// this.expected = expected;
+ this.affectedClass = clazz;
+ this.affectedField = field;
+ this.affectedMethod = method;
}
/**
@@ -54,7 +85,7 @@
* definately break, WARNING means that clients may break, depending
* on how they use the library. See the eclipse paper for further
* explanation.
- *
+ *
* @return the severity of the API difference.
*/
public Severity getSeverity()
@@ -62,25 +93,42 @@
return severity;
}
+ /**
+ * Human readable api change description.
+ *
+ * @return a human readable description of this API difference.
+ */
public String getReport()
{
return report;
}
- /*
- public boolean isExpected()
+ public String getAffectedClass()
+ {
+ return affectedClass;
+ }
+
+ public String getAffectedMethod()
+ {
+ return affectedMethod;
+ }
+
+ public String getAffectedField()
{
- return expected;
+ return affectedField;
}
- */
- /** {@inheritDoc} */
+ /**
+ * {@inheritDoc}
+ */
public String toString()
{
- return report + " (" + severity + ")";
+ return report + " (" + severity + ')';
}
- /** {@inheritDoc} */
+ /**
+ * {@inheritDoc}
+ */
public boolean equals(Object o)
{
if (this == o)
@@ -93,13 +141,25 @@
return false;
}
- final ApiDifference apiDifference = (ApiDifference) o;
+ final ApiDifference other = (ApiDifference) o;
- if (report != null ? !report.equals(apiDifference.report) : apiDifference.report != null)
+ if (report != null ? !report.equals(other.report) : other.report != null)
+ {
+ return false;
+ }
+ if (severity != null ? !severity.equals(other.severity) : other.severity != null)
+ {
+ return false;
+ }
+ if (affectedClass != null ? !affectedClass.equals(other.affectedClass) : other.affectedClass != null)
+ {
+ return false;
+ }
+ if (affectedMethod != null ? !affectedMethod.equals(other.affectedMethod) : other.affectedMethod != null)
{
return false;
}
- if (severity != null ? !severity.equals(apiDifference.severity) : apiDifference.severity != null)
+ if (affectedField != null ? !affectedField.equals(other.affectedField) : other.affectedField != null)
{
return false;
}
@@ -110,8 +170,11 @@
public int hashCode()
{
int result;
- result = (report != null ? report.hashCode() : 0);
- result = 29 * result + (severity != null ? severity.hashCode() : 0);
+ result = report != null ? report.hashCode() : 0;
+ result = HASHCODE_MAGIC * result + (severity != null ? severity.hashCode() : 0);
+ result = HASHCODE_MAGIC * result + (affectedClass != null ? affectedClass.hashCode() : 0);
+ result = HASHCODE_MAGIC * result + (affectedMethod != null ? affectedMethod.hashCode() : 0);
+ result = HASHCODE_MAGIC * result + (affectedField != null ? affectedField.hashCode() : 0);
return result;
}
}
Index: FileDiffListener.java
===================================================================
RCS file: /cvsroot/clirr/clirr/src/java/net/sf/clirr/event/FileDiffListener.java,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -r1.5 -r1.6
--- FileDiffListener.java 27 Sep 2003 05:28:43 -0000 1.5
+++ FileDiffListener.java 27 Dec 2003 19:08:42 -0000 1.6
@@ -43,12 +43,12 @@
{
if (outFile == null)
{
- this.outputStream = System.out;
+ outputStream = System.out;
}
else
{
final OutputStream out = new FileOutputStream(outFile);
- this.outputStream = new PrintStream(out);
+ outputStream = new PrintStream(out);
}
}
Index: XmlDiffListener.java
===================================================================
RCS file: /cvsroot/clirr/clirr/src/java/net/sf/clirr/event/XmlDiffListener.java,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -r1.5 -r1.6
--- XmlDiffListener.java 27 Dec 2003 17:43:53 -0000 1.5
+++ XmlDiffListener.java 27 Dec 2003 19:08:42 -0000 1.6
@@ -26,7 +26,7 @@
* A DiffListener that reports any detected difference to
* an XML file. That file can be used by subsequent processing steps
* to create nice looking reports in HTML, PDF, etc.
- *
+ *
* @author lkuehne
*/
public final class XmlDiffListener extends FileDiffListener
@@ -44,12 +44,22 @@
PrintStream out = getOutputStream();
out.print(" <" + DIFFERENCE);
out.print(" severity=\"" + difference.getSeverity() + "\">");
+ out.print(" class=\"" + difference.getAffectedClass() + "\"");
+ if (difference.getAffectedMethod() != null)
+ {
+ out.print(" method=\"" + difference.getAffectedMethod() + "\"");
+ }
+ if (difference.getAffectedField() != null)
+ {
+ out.print(" field=\"" + difference.getAffectedField() + "\"");
+ }
out.print(difference.getReport()); // TODO: XML escapes??
out.println("</" + DIFFERENCE + '>');
}
/**
* Writes an XML header and toplevel tag to the xml stream.
+ *
* @see DiffListener#start()
*/
public void start()
@@ -70,6 +80,7 @@
/**
* Closes the toplevel tag that was opened in start.
+ *
* @see DiffListener#stop()
*/
protected void writeFooter()
|
Update of /cvsroot/clirr/clirr/src/java/net/sf/clirr/checks
In directory sc8-pr-cvs1:/tmp/cvs-serv6028/src/java/net/sf/clirr/checks
Modified Files:
AbstractClassSetChangeCheck.java ClassHierarchyCheck.java
ClassModifierCheck.java GenderChangeCheck.java
InterfaceSetCheck.java
Log Message:
added information about affected class/method/field to ApiDifference
This is a first step towards filtering diffs to let the user specify changes that are OK
Index: AbstractClassSetChangeCheck.java
===================================================================
RCS file: /cvsroot/clirr/clirr/src/java/net/sf/clirr/checks/AbstractClassSetChangeCheck.java,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -r1.6 -r1.7
--- AbstractClassSetChangeCheck.java 27 Sep 2003 05:28:43 -0000 1.6
+++ AbstractClassSetChangeCheck.java 27 Dec 2003 19:08:42 -0000 1.7
@@ -44,7 +44,7 @@
String oldClassName = setA[i];
if (Arrays.binarySearch(setB, oldClassName) < 0)
{
- log(diffPrefix + oldClassName, severity);
+ log(diffPrefix + oldClassName, severity, oldClassName, null, null);
}
}
}
Index: ClassHierarchyCheck.java
===================================================================
RCS file: /cvsroot/clirr/clirr/src/java/net/sf/clirr/checks/ClassHierarchyCheck.java,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -r1.6 -r1.7
--- ClassHierarchyCheck.java 27 Sep 2003 05:28:43 -0000 1.6
+++ ClassHierarchyCheck.java 27 Dec 2003 19:08:42 -0000 1.7
@@ -77,18 +77,19 @@
List added = getSetDifference(currentSuper, compatSuper);
List removed = getSetDifference(compatSuper, currentSuper);
+ final String className = compatBaseline.getClassName();
for (int i = 0; i < added.size(); i++)
{
String s = (String) added.get(i);
- log("Added " + s + " to the list of superclasses of "
- + compatBaseline.getClassName(), Severity.INFO);
+ log("Added " + s + " to the list of superclasses of " + className,
+ Severity.INFO, className, null, null);
}
for (int i = 0; i < removed.size(); i++)
{
String s = (String) removed.get(i);
- log("Removed " + s + " from the list of superclasses of "
- + compatBaseline.getClassName(), Severity.ERROR);
+ log("Removed " + s + " from the list of superclasses of " + className,
+ Severity.ERROR, className, null, null);
}
}
}
Index: ClassModifierCheck.java
===================================================================
RCS file: /cvsroot/clirr/clirr/src/java/net/sf/clirr/checks/ClassModifierCheck.java,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -r1.6 -r1.7
--- ClassModifierCheck.java 27 Sep 2003 05:28:43 -0000 1.6
+++ ClassModifierCheck.java 27 Dec 2003 19:08:42 -0000 1.7
@@ -62,21 +62,25 @@
if (compatIsFinal && !currentIsFinal)
{
- log("Removed final modifier in class " + className, Severity.INFO);
+ log("Removed final modifier in class " + className,
+ Severity.INFO, className, null, null);
}
else if (!compatIsFinal && currentIsFinal)
{
- log("Added final modifier in class " + className, Severity.ERROR);
+ log("Added final modifier in class " + className,
+ Severity.ERROR, className, null, null);
}
// interfaces are always abstract, don't report gender change here
if (compatIsAbstract && !currentIsAbstract && !compatIsInterface)
{
- log("Removed abstract modifier in class " + className, Severity.INFO);
+ log("Removed abstract modifier in class " + className,
+ Severity.INFO, className, null, null);
}
else if (!compatIsAbstract && currentIsAbstract && !currentIsInterface)
{
- log("Added abstract modifier in class " + className, Severity.ERROR);
+ log("Added abstract modifier in class " + className,
+ Severity.ERROR, className, null, null);
}
}
Index: GenderChangeCheck.java
===================================================================
RCS file: /cvsroot/clirr/clirr/src/java/net/sf/clirr/checks/GenderChangeCheck.java,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -r1.5 -r1.6
--- GenderChangeCheck.java 27 Sep 2003 05:28:43 -0000 1.5
+++ GenderChangeCheck.java 27 Dec 2003 19:08:42 -0000 1.6
@@ -57,7 +57,8 @@
if (baseLine.isClass() != current.isClass())
{
getApiDiffDispatcher().fireDiff(new ApiDifference(
- "Changed Gender of " + baseLine.getClassName(), Severity.ERROR)
+ "Changed Gender of " + baseLine.getClassName(), Severity.ERROR,
+ baseLine.getClassName(), null, null)
);
}
}
Index: InterfaceSetCheck.java
===================================================================
RCS file: /cvsroot/clirr/clirr/src/java/net/sf/clirr/checks/InterfaceSetCheck.java,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -r1.5 -r1.6
--- InterfaceSetCheck.java 27 Sep 2003 05:28:43 -0000 1.5
+++ InterfaceSetCheck.java 27 Dec 2003 19:08:42 -0000 1.6
@@ -73,7 +73,7 @@
log("Removed " + compatInterface
+ " from the set of interfaces implemented by "
+ className,
- Severity.ERROR);
+ Severity.ERROR, className, null, null);
}
else
{
@@ -89,7 +89,7 @@
log("Added " + name
+ " to the set of implemented interfaces implemented by "
+ className,
- Severity.INFO);
+ Severity.INFO, className, null, null);
}
}
}
|
|
From: Lars K?h. <lk...@us...> - 2003-12-27 17:48:41
|
Update of /cvsroot/clirr/clirr/src/java/net/sf/clirr
In directory sc8-pr-cvs1:/tmp/cvs-serv26006/src/java/net/sf/clirr
Modified Files:
Checker.java
Log Message:
fixed some findings of IDEA InspectionGadgets plugin
Index: Checker.java
===================================================================
RCS file: /cvsroot/clirr/clirr/src/java/net/sf/clirr/Checker.java,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -r1.5 -r1.6
--- Checker.java 29 Sep 2003 05:26:12 -0000 1.5
+++ Checker.java 27 Dec 2003 17:47:16 -0000 1.6
@@ -193,7 +193,7 @@
}
catch (IOException ex)
{
- throw new BuildException("Cannot read " + zipEntry + " from " + zip, ex);
+ throw new BuildException("Cannot read " + zipEntry.getName() + " from " + zip.getName(), ex);
}
finally
{
@@ -205,7 +205,7 @@
}
catch (IOException ex)
{
- throw new BuildException(ex);
+ throw new BuildException("Cannot close " + zip.getName(), ex);
}
}
}
@@ -224,7 +224,9 @@
}
catch (MalformedURLException ex)
{
- throw new RuntimeException("Cannot create classloader with jar file " + jarFile);
+ final IllegalArgumentException illegalArgumentException = new IllegalArgumentException("Cannot create classloader with jar file " + jarFile);
+ illegalArgumentException.initCause(ex);
+ throw illegalArgumentException;
}
}
final URLClassLoader jarsLoader = new URLClassLoader(jarUrls, thirdPartyClasses);
|
|
From: Lars K?h. <lk...@us...> - 2003-12-27 17:46:17
|
Update of /cvsroot/clirr/clirr/src/test/net/sf/clirr/checks
In directory sc8-pr-cvs1:/tmp/cvs-serv25789/src/test/net/sf/clirr/checks
Modified Files:
TestDiffListener.java
Log Message:
fixed some findings of IDEA InspectionGadgets plugin
Index: TestDiffListener.java
===================================================================
RCS file: /cvsroot/clirr/clirr/src/test/net/sf/clirr/checks/TestDiffListener.java,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- TestDiffListener.java 5 Oct 2003 17:54:35 -0000 1.1
+++ TestDiffListener.java 27 Dec 2003 17:45:30 -0000 1.2
@@ -19,7 +19,7 @@
public void checkExpected(ApiDifference[] expected)
{
- HashSet expectedDiffs = new HashSet();
+ HashSet expectedDiffs = new HashSet(expected.length);
for (int i = 0; i < expected.length; i++) {
ApiDifference apiDifference = expected[i];
expectedDiffs.add(apiDifference);
|
|
From: Lars K?h. <lk...@us...> - 2003-12-27 17:45:26
|
Update of /cvsroot/clirr/clirr/src/java/net/sf/clirr/ant
In directory sc8-pr-cvs1:/tmp/cvs-serv25665/src/java/net/sf/clirr/ant
Modified Files:
AntLogger.java
Log Message:
fixed some findings of IDEA InspectionGadgets plugin
Index: AntLogger.java
===================================================================
RCS file: /cvsroot/clirr/clirr/src/java/net/sf/clirr/ant/AntLogger.java,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- AntLogger.java 27 Sep 2003 05:28:43 -0000 1.3
+++ AntLogger.java 27 Dec 2003 17:44:59 -0000 1.4
@@ -32,7 +32,7 @@
{
private Task task;
- private Map severityPrioMap = new HashMap();
+ private Map severityPrioMap = new HashMap(3);
AntLogger(Task task)
{
|
|
From: Lars K?h. <lk...@us...> - 2003-12-27 17:44:38
|
Update of /cvsroot/clirr/clirr/src/test/net/sf/clirr/ant
In directory sc8-pr-cvs1:/tmp/cvs-serv25605/src/test/net/sf/clirr/ant
Modified Files:
ChangeCounterTest.java
Log Message:
fixed some findings of IDEA InspectionGadgets plugin
Index: ChangeCounterTest.java
===================================================================
RCS file: /cvsroot/clirr/clirr/src/test/net/sf/clirr/ant/ChangeCounterTest.java,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- ChangeCounterTest.java 5 Oct 2003 17:54:35 -0000 1.1
+++ ChangeCounterTest.java 27 Dec 2003 17:44:17 -0000 1.2
@@ -15,8 +15,8 @@
counter.reportDiff(new ApiDifference("blah", Severity.ERROR));
counter.reportDiff(new ApiDifference("blah", Severity.ERROR));
counter.reportDiff(new ApiDifference("blah", Severity.WARNING));
- assertEquals(3, counter.getErrors());
- assertEquals(2, counter.getWarnings());
- assertEquals(1, counter.getInfos());
+ assertEquals("number of expected errors", 3, counter.getErrors());
+ assertEquals("number of expected warnings", 2, counter.getWarnings());
+ assertEquals("number of expected infos", 1, counter.getInfos());
}
}
|
|
From: Lars K?h. <lk...@us...> - 2003-12-27 17:43:58
|
Update of /cvsroot/clirr/clirr/src/java/net/sf/clirr/event
In directory sc8-pr-cvs1:/tmp/cvs-serv25544/src/java/net/sf/clirr/event
Modified Files:
XmlDiffListener.java
Log Message:
fixed some findings of IDEA InspectionGadgets plugin
Index: XmlDiffListener.java
===================================================================
RCS file: /cvsroot/clirr/clirr/src/java/net/sf/clirr/event/XmlDiffListener.java,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -r1.4 -r1.5
--- XmlDiffListener.java 27 Sep 2003 05:28:43 -0000 1.4
+++ XmlDiffListener.java 27 Dec 2003 17:43:53 -0000 1.5
@@ -45,7 +45,7 @@
out.print(" <" + DIFFERENCE);
out.print(" severity=\"" + difference.getSeverity() + "\">");
out.print(difference.getReport()); // TODO: XML escapes??
- out.println("</" + DIFFERENCE + ">");
+ out.println("</" + DIFFERENCE + '>');
}
/**
@@ -56,7 +56,7 @@
{
PrintStream out = getOutputStream();
out.println("<?xml version=\"1.0\"?>");
- out.println("<" + DIFFREPORT + ">");
+ out.println('<' + DIFFREPORT + '>');
out.println("<!--");
out.println(" In future versions the differences will have more attributes, e.g.");
out.println(" - affected package");
@@ -75,6 +75,6 @@
protected void writeFooter()
{
PrintStream out = getOutputStream();
- out.println("</" + DIFFREPORT + ">");
+ out.println("</" + DIFFREPORT + '>');
}
}
|
|
From: Lars K?h. <lk...@us...> - 2003-10-16 05:41:59
|
Update of /cvsroot/clirr/clirr/xdocs
In directory sc8-pr-cvs1:/tmp/cvs-serv8770
Modified Files:
anttask.xml
Log Message:
fixed xml error in ant setup code
Index: anttask.xml
===================================================================
RCS file: /cvsroot/clirr/clirr/xdocs/anttask.xml,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- anttask.xml 15 Sep 2003 05:58:46 -0000 1.2
+++ anttask.xml 16 Oct 2003 05:41:46 -0000 1.3
@@ -34,8 +34,8 @@
<get src="${url.libbase}/${ant.project.name}/${jar.baseline}" dest="build/tmp/${jar.baseline}"/>
<clirr>
- <origfiles dir="build/tmp" includes="${jar.baseline}">
- <newfiles dir="build/lib" includes="${jar.buildresult}">
+ <origfiles dir="build/tmp" includes="${jar.baseline}"/>
+ <newfiles dir="build/lib" includes="${jar.buildresult}"/>
<!-- <formatter type="xml" outfile="build/clirr.xml" /> -->
<!-- TODO: example for 3rd party classpath -->
@@ -126,4 +126,4 @@
</section>
</section>
</body>
-</document>
\ No newline at end of file
+</document>
|
|
From: Lars K?h. <lk...@us...> - 2003-10-05 18:02:06
|
Update of /cvsroot/clirr/clirr
In directory sc8-pr-cvs1:/tmp/cvs-serv24715
Modified Files:
project.xml
Log Message:
speed up site generation by leaving out non-essential reports
Index: project.xml
===================================================================
RCS file: /cvsroot/clirr/clirr/project.xml,v
retrieving revision 1.12
retrieving revision 1.13
diff -u -r1.12 -r1.13
--- project.xml 27 Sep 2003 11:18:43 -0000 1.12
+++ project.xml 5 Oct 2003 18:01:56 -0000 1.13
@@ -127,9 +127,6 @@
<includes>
<include>**/*Test.java</include>
</includes>
- <excludes>
- <exclude>**/NaughtyTest.java</exclude>
- </excludes>
</unitTest>
<resources>
@@ -140,17 +137,17 @@
</build>
<reports>
- <report>maven-changelog-plugin</report> -->
- <report>maven-changes-plugin</report>
+<!-- <report>maven-changelog-plugin</report> -->
+<!-- <report>maven-changes-plugin</report> -->
<report>maven-checkstyle-plugin</report>
- <report>maven-developer-activity-plugin</report> -->
- <report>maven-file-activity-plugin</report> -->
+<!-- <report>maven-developer-activity-plugin</report> -->
+<!-- <report>maven-file-activity-plugin</report> -->
<report>maven-javadoc-plugin</report>
<report>maven-jdepend-plugin</report>
<report>maven-junit-report-plugin</report>
<report>maven-jxr-plugin</report>
<report>maven-license-plugin</report>
- <report>maven-linkcheck-plugin</report>
+<!-- <report>maven-linkcheck-plugin</report> -->
<!-- we got checkstyle already, so who needs pmd... :-) -->
<report>maven-tasklist-plugin</report>
</reports>
|
|
From: Lars K?h. <lk...@us...> - 2003-10-05 17:59:15
|
Update of /cvsroot/clirr/clirr/conf
In directory sc8-pr-cvs1:/tmp/cvs-serv24106/conf
Modified Files:
clirr_checks.xml
Log Message:
allow inline conditionals
Index: clirr_checks.xml
===================================================================
RCS file: /cvsroot/clirr/clirr/conf/clirr_checks.xml,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- clirr_checks.xml 20 Sep 2003 13:04:59 -0000 1.2
+++ clirr_checks.xml 5 Oct 2003 17:59:11 -0000 1.3
@@ -150,7 +150,7 @@
<!-- Checks for common coding problems -->
<!-- See http://checkstyle.sf.net/config_coding.html -->
- <module name="AvoidInlineConditionals"/>
+ <!-- <module name="AvoidInlineConditionals"/> not necessary for clirr, all developers are smart enough to figure out the meaning of "?:" -->
<module name="DoubleCheckedLocking"/> <!-- MY FAVOURITE -->
<module name="EmptyStatement"/>
<module name="EqualsHashCode"/>
|
|
From: Lars K?h. <lk...@us...> - 2003-10-05 17:58:24
|
Update of /cvsroot/clirr/clirr/xdocs
In directory sc8-pr-cvs1:/tmp/cvs-serv23970/xdocs
Modified Files:
navigation.xml
Log Message:
first you download, then you run
Index: navigation.xml
===================================================================
RCS file: /cvsroot/clirr/clirr/xdocs/navigation.xml,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -r1.5 -r1.6
--- navigation.xml 27 Sep 2003 11:50:09 -0000 1.5
+++ navigation.xml 5 Oct 2003 17:58:20 -0000 1.6
@@ -11,10 +11,10 @@
<menu name="Clirr">
<item name="Overview"
href="/index.html"/>
- <item name="Running Clirr"
- href="/anttask.html"/>
<item name="Download"
href="/download.html"/>
+ <item name="Running Clirr"
+ href="/anttask.html"/>
<item name="Contributing"
href="/contributing.html"/>
<item name="Related tools"
|
|
From: Lars K?h. <lk...@us...> - 2003-10-05 17:56:39
|
Update of /cvsroot/clirr/clirr/src/java/net/sf/clirr/event
In directory sc8-pr-cvs1:/tmp/cvs-serv23633/src/java/net/sf/clirr/event
Modified Files:
ApiDifference.java
Log Message:
override equals so unit tests can compare expected and actual ApiDiffs
Index: ApiDifference.java
===================================================================
RCS file: /cvsroot/clirr/clirr/src/java/net/sf/clirr/event/ApiDifference.java,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- ApiDifference.java 27 Sep 2003 05:28:43 -0000 1.3
+++ ApiDifference.java 5 Oct 2003 17:56:31 -0000 1.4
@@ -34,15 +34,29 @@
private Severity severity;
- private boolean expected;
+ //private boolean expected;
+ /**
+ * Create a new API differnce representation.
+ *
+ * @param report a human readable string describing the change that was made.
+ * @param severity the severity in terms of binary API compatibility.
+ */
public ApiDifference(String report, Severity severity /*, boolean expected*/)
{
this.report = report;
this.severity = severity;
- this.expected = expected;
+// this.expected = expected;
}
+ /**
+ * The Severity of the API difference. ERROR means that clients will
+ * definately break, WARNING means that clients may break, depending
+ * on how they use the library. See the eclipse paper for further
+ * explanation.
+ *
+ * @return the severity of the API difference.
+ */
public Severity getSeverity()
{
return severity;
@@ -53,13 +67,51 @@
return report;
}
+ /*
public boolean isExpected()
{
return expected;
}
+ */
+ /** {@inheritDoc} */
public String toString()
{
- return report;
+ return report + " (" + severity + ")";
+ }
+
+ /** {@inheritDoc} */
+ public boolean equals(Object o)
+ {
+ if (this == o)
+ {
+ return true;
+ }
+
+ if (!(o instanceof ApiDifference))
+ {
+ return false;
+ }
+
+ final ApiDifference apiDifference = (ApiDifference) o;
+
+ if (report != null ? !report.equals(apiDifference.report) : apiDifference.report != null)
+ {
+ return false;
+ }
+ if (severity != null ? !severity.equals(apiDifference.severity) : apiDifference.severity != null)
+ {
+ return false;
+ }
+
+ return true;
+ }
+
+ public int hashCode()
+ {
+ int result;
+ result = (report != null ? report.hashCode() : 0);
+ result = 29 * result + (severity != null ? severity.hashCode() : 0);
+ return result;
}
}
|