Author: erans
Date: Wed Jul 13 15:28:21 2011
New Revision: 1146099

URL: http://svn.apache.org/viewvc?rev=1146099&view=rev
Log:
MATH-566
Removed unused "MathRuntimeException".

Removed:
    
commons/proper/math/trunk/src/main/java/org/apache/commons/math/exception/MathRuntimeException.java
    
commons/proper/math/trunk/src/test/java/org/apache/commons/math/exception/MathRuntimeExceptionTest.java
Modified:
    
commons/proper/math/trunk/src/main/java/org/apache/commons/math/analysis/interpolation/UnivariateRealInterpolator.java
    
commons/proper/math/trunk/src/main/java/org/apache/commons/math/exception/MathThrowable.java
    
commons/proper/math/trunk/src/test/java/org/apache/commons/math/RetryRunnerTest.java

Modified: 
commons/proper/math/trunk/src/main/java/org/apache/commons/math/analysis/interpolation/UnivariateRealInterpolator.java
URL: 
http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math/analysis/interpolation/UnivariateRealInterpolator.java?rev=1146099&r1=1146098&r2=1146099&view=diff
==============================================================================
--- 
commons/proper/math/trunk/src/main/java/org/apache/commons/math/analysis/interpolation/UnivariateRealInterpolator.java
 (original)
+++ 
commons/proper/math/trunk/src/main/java/org/apache/commons/math/analysis/interpolation/UnivariateRealInterpolator.java
 Wed Jul 13 15:28:21 2011
@@ -30,8 +30,9 @@ public interface UnivariateRealInterpola
      * @param xval Arguments for the interpolation points.
      * @param yval Values for the interpolation points.
      * @return a function which interpolates the dataset.
-     * @throws org.apache.commons.math.exception.MathRuntimeException if the
-     * arguments violate assumptions made by the interpolation algorithm.
+     * @throws org.apache.commons.math.exception.MathIllegalArgumentException
+     * if the arguments violate assumptions made by the interpolation
+     * algorithm.
      */
     UnivariateRealFunction interpolate(double xval[], double yval[]);
 }

Modified: 
commons/proper/math/trunk/src/main/java/org/apache/commons/math/exception/MathThrowable.java
URL: 
http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math/exception/MathThrowable.java?rev=1146099&r1=1146098&r2=1146099&view=diff
==============================================================================
--- 
commons/proper/math/trunk/src/main/java/org/apache/commons/math/exception/MathThrowable.java
 (original)
+++ 
commons/proper/math/trunk/src/main/java/org/apache/commons/math/exception/MathThrowable.java
 Wed Jul 13 15:28:21 2011
@@ -26,6 +26,9 @@ import org.apache.commons.math.exception
 *
 * @version $Id$
 * @since 2.2
+* @deprecated To be removed in 3.0. Not deleted right-away because
+* the Javadoc is inherited in old "o.a.c.math.MathException" and
+* "o.a.c.math.MathRuntimeException" classes.
 */
 public interface MathThrowable {
     /**

Modified: 
commons/proper/math/trunk/src/test/java/org/apache/commons/math/RetryRunnerTest.java
URL: 
http://svn.apache.org/viewvc/commons/proper/math/trunk/src/test/java/org/apache/commons/math/RetryRunnerTest.java?rev=1146099&r1=1146098&r2=1146099&view=diff
==============================================================================
--- 
commons/proper/math/trunk/src/test/java/org/apache/commons/math/RetryRunnerTest.java
 (original)
+++ 
commons/proper/math/trunk/src/test/java/org/apache/commons/math/RetryRunnerTest.java
 Wed Jul 13 15:28:21 2011
@@ -19,7 +19,7 @@ package org.apache.commons.math;
 
 import java.util.Random;
 
-import org.apache.commons.math.exception.MathRuntimeException;
+import org.apache.commons.math.exception.MathIllegalStateException;
 
 import org.junit.Test;
 import org.junit.runner.RunWith;
@@ -34,10 +34,10 @@ public class RetryRunnerTest {
     /**
      * Shows that an always failing test will fail even if it is retried.
      */
-    @Test(expected=MathRuntimeException.class)
+    @Test(expected=MathIllegalStateException.class)
     @Retry
     public void testRetryFailAlways() {
-        throw new MathRuntimeException();
+        throw new MathIllegalStateException();
     }
 
     /**
@@ -49,7 +49,7 @@ public class RetryRunnerTest {
     @Retry(100)
     public void testRetryFailSometimes() {
         if (rng.nextBoolean()) {
-            throw new MathRuntimeException();
+            throw new MathIllegalStateException();
         }
     }
 }


Reply via email to