2003-12-19 Michael Koch <konqueror@gmx.de>
authorMichael Koch <konqueror@gmx.de>
Fri, 19 Dec 2003 09:53:06 +0000 (09:53 +0000)
committerMichael Koch <mkoch@gcc.gnu.org>
Fri, 19 Dec 2003 09:53:06 +0000 (09:53 +0000)
* java/text/MessageFormat.java
(MessageFormat): New constructor.

From-SVN: r74828

libjava/ChangeLog
libjava/java/text/MessageFormat.java

index aeca31281e8f20a3c8a4d435b554f1bc4c1fb42b..50cf99a3cc6c13d4f840f4dd26e34d1ea6e64abd 100644 (file)
@@ -1,3 +1,8 @@
+2003-12-19  Michael Koch  <konqueror@gmx.de>
+
+       * java/text/MessageFormat.java
+       (MessageFormat): New constructor.
+
 2003-12-19  Michael Koch  <konqueror@gmx.de>
 
        * gnu/java/net/protocol/jar/Handler.java
index caeb7265f46c4dc5ece3951d3c49dfcb0a68f0b4..e34fe2c89d1bd2beaab503e0e67c86c137d2b1e0 100644 (file)
@@ -454,11 +454,25 @@ public class MessageFormat extends Format
    * Creates a new MessageFormat object with
    * the specified pattern
    *
-   * @param aPattern The Pattern
+   * @param pattern The Pattern
+   */
+  public MessageFormat(String pattern)
+  {
+    this(pattern, Locale.getDefault());
+  }
+
+  /**
+   * Creates a new MessageFormat object with
+   * the specified pattern
+   *
+   * @param pattern The Pattern
+   * @param locale The Locale to use
+   *
+   * @since 1.4
    */
-  public MessageFormat (String pattern)
+  public MessageFormat(String pattern, Locale locale)
   {
-    locale = Locale.getDefault();
+    this.locale = locale;
     applyPattern (pattern);
   }