commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Anaximandro (Woody)" <agodinh...@globo.com>
Subject [i18n] suggestion patch - LocalizedException
Date Tue, 01 Feb 2005 08:32:53 GMT
"final" enhancements
Index: LocalizedException.java
===================================================================
RCS file:
/home/cvspublic/jakarta-commons-sandbox/i18n/src/java/org/apache/commons/i18
n/LocalizedException.java,v
retrieving revision 1.1
diff -u -r1.1 LocalizedException.java
--- LocalizedException.java 4 Oct 2004 13:41:09 -0000 1.1
+++ LocalizedException.java 1 Feb 2005 03:27:55 -0000
@@ -25,19 +25,19 @@
 import java.util.Locale;

 public class LocalizedException extends Exception {
-    private LocalizedError errorMessage;
+    private final LocalizedError errorMessage;

-    public LocalizedException(LocalizedError errorMessage, Throwable
throwable) {
+    public LocalizedException(final LocalizedError errorMessage, final
Throwable throwable) {
         super(errorMessage.getSummary(Locale.getDefault(),
throwable.getMessage()), throwable);
         this.errorMessage = errorMessage;
     }

-    public LocalizedException(LocalizedError errorMessage) {
+    public LocalizedException(final LocalizedError errorMessage) {
         super(errorMessage.getSummary(Locale.getDefault(), "no message
available"));
         this.errorMessage = errorMessage;
     }

     public LocalizedError getErrorMessage() {
-        return errorMessage;
+        return this.errorMessage;
     }
 }
\ No newline at end of file


---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-dev-help@jakarta.apache.org


Mime
View raw message