You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@harmony.apache.org by hi...@apache.org on 2010/02/06 08:25:23 UTC

svn commit: r907186 - in /harmony/enhanced/classlib/branches/java6/modules: luni/src/main/java/java/io/File.java text/src/main/java/java/text/CollationKey.java

Author: hindessm
Date: Sat Feb  6 07:25:22 2010
New Revision: 907186

URL: http://svn.apache.org/viewvc?rev=907186&view=rev
Log:
Java6 api compatibility.

Modified:
    harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/java/io/File.java
    harmony/enhanced/classlib/branches/java6/modules/text/src/main/java/java/text/CollationKey.java

Modified: harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/java/io/File.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/java/io/File.java?rev=907186&r1=907185&r2=907186&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/java/io/File.java (original)
+++ harmony/enhanced/classlib/branches/java6/modules/luni/src/main/java/java/io/File.java Sat Feb  6 07:25:22 2010
@@ -1586,7 +1586,11 @@
      * @return a URL for this file.
      * @throws java.net.MalformedURLException
      *             if the path cannot be transformed into a URL.
+     *
+     * @deprecated use {@link #toURI} and {@link java.net.URI#toURL} to get
+     * correct escaping of illegal characters.
      */
+    @Deprecated
     @SuppressWarnings("nls")
     public URL toURL() throws java.net.MalformedURLException {
         String name = getAbsoluteName();

Modified: harmony/enhanced/classlib/branches/java6/modules/text/src/main/java/java/text/CollationKey.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/branches/java6/modules/text/src/main/java/java/text/CollationKey.java?rev=907186&r1=907185&r2=907186&view=diff
==============================================================================
--- harmony/enhanced/classlib/branches/java6/modules/text/src/main/java/java/text/CollationKey.java (original)
+++ harmony/enhanced/classlib/branches/java6/modules/text/src/main/java/java/text/CollationKey.java Sat Feb  6 07:25:22 2010
@@ -78,11 +78,11 @@
  * @see Collator
  * @see RuleBasedCollator
  */
-public final class CollationKey implements Comparable<CollationKey> {
+public class CollationKey implements Comparable<CollationKey> {
 
-    private String source;
+    private final String source;
 
-    private com.ibm.icu.text.CollationKey icuKey;
+    private final com.ibm.icu.text.CollationKey icuKey;
 
     CollationKey(String source, com.ibm.icu.text.CollationKey key) {
         this.source = source;