commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From t.@apache.org
Subject svn commit: r1240291 - /commons/proper/math/trunk/src/main/java/org/apache/commons/math/stat/descriptive/MultivariateSummaryStatistics.java
Date Fri, 03 Feb 2012 18:57:36 GMT
Author: tn
Date: Fri Feb  3 18:57:35 2012
New Revision: 1240291

URL: http://svn.apache.org/viewvc?rev=1240291&view=rev
Log:
Removed usage of MathRuntimeException in MultivariateSummaryStatistics.
JIRA: MATH-459

Modified:
    commons/proper/math/trunk/src/main/java/org/apache/commons/math/stat/descriptive/MultivariateSummaryStatistics.java

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math/stat/descriptive/MultivariateSummaryStatistics.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math/stat/descriptive/MultivariateSummaryStatistics.java?rev=1240291&r1=1240290&r2=1240291&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math/stat/descriptive/MultivariateSummaryStatistics.java
(original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math/stat/descriptive/MultivariateSummaryStatistics.java
Fri Feb  3 18:57:35 2012
@@ -19,9 +19,9 @@ package org.apache.commons.math.stat.des
 import java.io.Serializable;
 import java.util.Arrays;
 
-import org.apache.commons.math.MathRuntimeException;
 import org.apache.commons.math.exception.util.LocalizedFormats;
 import org.apache.commons.math.exception.DimensionMismatchException;
+import org.apache.commons.math.exception.MathIllegalStateException;
 import org.apache.commons.math.linear.RealMatrix;
 import org.apache.commons.math.stat.descriptive.moment.GeometricMean;
 import org.apache.commons.math.stat.descriptive.moment.Mean;
@@ -605,13 +605,13 @@ public class MultivariateSummaryStatisti
     }
 
     /**
-     * Throws IllegalStateException if n > 0.
+     * Throws MathIllegalStateException if the statistic is not empty.
+     * @throws MathIllegalStateException if n > 0.
      */
     private void checkEmpty() {
         if (n > 0) {
-            throw MathRuntimeException.createIllegalStateException(
-                    LocalizedFormats.VALUES_ADDED_BEFORE_CONFIGURING_STATISTIC,
-                    n);
+            throw new MathIllegalStateException(
+                    LocalizedFormats.VALUES_ADDED_BEFORE_CONFIGURING_STATISTIC, n);
         }
     }
 



Mime
View raw message