You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@commons.apache.org by er...@apache.org on 2010/11/29 02:43:13 UTC
svn commit: r1040003 - in /commons/proper/math/trunk/src/main:
java/org/apache/commons/math/exception/
java/org/apache/commons/math/exception/util/ resources/META-INF/localization/
Author: erans
Date: Mon Nov 29 01:43:12 2010
New Revision: 1040003
URL: http://svn.apache.org/viewvc?rev=1040003&view=rev
Log:
Added "vararg" parameter to allow "specific" meessage patterns to make use
of additional information.
Modified:
commons/proper/math/trunk/src/main/java/org/apache/commons/math/exception/MaxCountExceededException.java
commons/proper/math/trunk/src/main/java/org/apache/commons/math/exception/NoBracketingException.java
commons/proper/math/trunk/src/main/java/org/apache/commons/math/exception/util/LocalizedFormats.java
commons/proper/math/trunk/src/main/resources/META-INF/localization/LocalizedFormats_fr.properties
Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math/exception/MaxCountExceededException.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math/exception/MaxCountExceededException.java?rev=1040003&r1=1040002&r2=1040003&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math/exception/MaxCountExceededException.java (original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math/exception/MaxCountExceededException.java Mon Nov 29 01:43:12 2010
@@ -46,10 +46,12 @@ public class MaxCountExceededException e
*
* @param specific Specific contexte pattern.
* @param max Maximum.
+ * @param args Additional arguments.
*/
public MaxCountExceededException(Localizable specific,
- Number max) {
- super(specific, LocalizedFormats.MAX_COUNT_EXCEEDED, max);
+ Number max,
+ Object ... args) {
+ super(specific, LocalizedFormats.MAX_COUNT_EXCEEDED, max, args);
this.max = max;
}
Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math/exception/NoBracketingException.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math/exception/NoBracketingException.java?rev=1040003&r1=1040002&r2=1040003&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math/exception/NoBracketingException.java (original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math/exception/NoBracketingException.java Mon Nov 29 01:43:12 2010
@@ -50,24 +50,7 @@ public class NoBracketingException exten
double fLo, double fHi) {
this(null, lo, hi, fLo, fHi);
}
- /**
- * Construct the exception with a specific context.
- *
- * @param specific Contextual information on what caused the exception.
- * @param lo Lower end of the interval.
- * @param hi Higher end of the interval.
- * @param fLo Value at lower end of the interval.
- * @param fHi Value at higher end of the interval.
- */
- public NoBracketingException(Localizable specific,
- double lo, double hi,
- double fLo, double fHi) {
- super(specific, LocalizedFormats.SAME_SIGN_AT_ENDPOINTS, lo, hi, fLo, fHi);
- this.lo = lo;
- this.hi = hi;
- this.fLo = fLo;
- this.fHi = fHi;
- }
+
/**
* Construct the exception with a specific context.
*
Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math/exception/util/LocalizedFormats.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math/exception/util/LocalizedFormats.java?rev=1040003&r1=1040002&r2=1040003&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math/exception/util/LocalizedFormats.java (original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math/exception/util/LocalizedFormats.java Mon Nov 29 01:43:12 2010
@@ -160,7 +160,7 @@ public enum LocalizedFormats implements
NUMBER_OF_TRIALS("number of trials ({0})"),
NEGATIVE_ROBUSTNESS_ITERATIONS("the number of robustness iterations must be non-negative, but got {0}"),
START_POSITION("start position ({0})"), /* keep */
- NON_CONVERGENT_CONTINUED_FRACTION("Continued fraction convergents failed to converge for value {0}"),
+ NON_CONVERGENT_CONTINUED_FRACTION("Continued fraction convergents failed to converge (in less than {0} iterations) for value {1}"),
NON_POSITIVE_MICROSPHERE_ELEMENTS("number of microsphere elements must be positive, but got {0}"),
NON_POSITIVE_POLYNOMIAL_DEGREE("polynomial degree must be positive: degree={0}"),
NON_REAL_FINITE_ABSCISSA("all abscissae must be finite real numbers, but {0}-th is {1}"),
Modified: commons/proper/math/trunk/src/main/resources/META-INF/localization/LocalizedFormats_fr.properties
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/resources/META-INF/localization/LocalizedFormats_fr.properties?rev=1040003&r1=1040002&r2=1040003&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/resources/META-INF/localization/LocalizedFormats_fr.properties (original)
+++ commons/proper/math/trunk/src/main/resources/META-INF/localization/LocalizedFormats_fr.properties Mon Nov 29 01:43:12 2010
@@ -132,7 +132,7 @@ NEGATIVE_NUMBER_OF_TRIALS = le nombre d'
NUMBER_OF_TRIALS = nombre d''essais ({0})
NEGATIVE_ROBUSTNESS_ITERATIONS = le nombre d''it\u00e9rations robuste ne peut \u00eatre n\u00e9gatif, alors qu''il est de {0}
START_POSITION = position de d\u00e9part
-NON_CONVERGENT_CONTINUED_FRACTION = \u00c9chec de convergence de fraction continue pour la valeur {0}
+NON_CONVERGENT_CONTINUED_FRACTION = \u00c9chec de convergence (en moins de {0} it\u00e9rations) de fraction continue pour la valeur {1}
NON_POSITIVE_MICROSPHERE_ELEMENTS = le nombre d''\u00e9l\u00e9ments de la microsph\u00e8re devrait \u00eatre positif, or n = {0}
NON_POSITIVE_POLYNOMIAL_DEGREE = le polyn\u00f4me doit \u00eatre de degr\u00e9 positif : degr\u00e9 = {0}
NON_REAL_FINITE_ABSCISSA = toutes les abscisses doivent \u00eatre des nombres r\u00e9els finis, mais l''abscisse {0} vaut {1}