AbstractPreferences.java, [...]: Reworked imports, removed unused imports.
authorMichael Koch <konqueror@gmx.de>
Tue, 17 Jun 2003 13:01:21 +0000 (13:01 +0000)
committerMichael Koch <mkoch@gcc.gnu.org>
Tue, 17 Jun 2003 13:01:21 +0000 (13:01 +0000)
2003-06-17  Michael Koch  <konqueror@gmx.de>

* java/util/prefs/AbstractPreferences.java,
java/util/prefs/PreferencesFactory.java:
Reworked imports, removed unused imports.
* java/util/prefs/Preferences.java
(systemNodeForPackage): Method takes a Class not an Object.
(userNodeForPackage): Likewise.
(nodeForPackage): Likewise.

From-SVN: r68081

libjava/ChangeLog
libjava/java/util/prefs/AbstractPreferences.java
libjava/java/util/prefs/Preferences.java
libjava/java/util/prefs/PreferencesFactory.java

index 2fd69fc030eab47ec7d765f8c6f91af1131e9eeb..969c17924af7bb3cf4c358388c6e91ce36c2442b 100644 (file)
@@ -1,3 +1,13 @@
+2003-06-17  Michael Koch  <konqueror@gmx.de>
+
+       * java/util/prefs/AbstractPreferences.java,
+       java/util/prefs/PreferencesFactory.java:
+       Reworked imports, removed unused imports.
+       * java/util/prefs/Preferences.java
+       (systemNodeForPackage): Method takes a Class not an Object.
+       (userNodeForPackage): Likewise.
+       (nodeForPackage): Likewise.
+
 2003-06-17  Michael Koch  <konqueror@gmx.de>
 
        * gnu/java/security/x509/X509Certificate.java:
index d192c1f671717754cae4964dcd915d7ccc21d410..a6a3e9a82f23f9f90aa33f7b4926e79d601cc955 100644 (file)
@@ -35,17 +35,15 @@ this exception to your version of the library, but you are not
 obligated to do so.  If you do not wish to do so, delete this
 exception statement from your version. */
 
+
 package java.util.prefs;
 
 import java.io.ByteArrayOutputStream;
 import java.io.IOException;
-import java.io.InputStream;
 import java.io.OutputStream;
-
 import java.util.Iterator;
 import java.util.HashMap;
 import java.util.TreeSet;
-
 import gnu.java.util.prefs.NodeWriter;
 
 /**
index 8705b77191cbf52fda9e8df06f41783384911ea1..af2535966bee3f7e54760cdb1fd93d0eaec918ac 100644 (file)
@@ -238,10 +238,10 @@ public abstract class Preferences {
      * @exception SecurityException when a security manager is installed and
      * the caller does not have <code>RuntimePermission("preferences")</code>.
      */
-    public static Preferences systemNodeForPackage(Object o)
+    public static Preferences systemNodeForPackage(Class c)
             throws SecurityException
     {
-        return nodeForPackage(o, systemRoot());
+        return nodeForPackage(c, systemRoot());
     }
 
     /**
@@ -257,10 +257,10 @@ public abstract class Preferences {
      * @exception SecurityException when a security manager is installed and
      * the caller does not have <code>RuntimePermission("preferences")</code>.
      */
-    public static Preferences userNodeForPackage(Object o)
+    public static Preferences userNodeForPackage(Class c)
             throws SecurityException
     {
-        return nodeForPackage(o, userRoot());
+        return nodeForPackage(c, userRoot());
     }
 
     /**
@@ -269,9 +269,9 @@ public abstract class Preferences {
      * root it returns the correct Preference node for the package node name
      * of the given object.
      */
-    private static Preferences nodeForPackage(Object o, Preferences root) {
+    private static Preferences nodeForPackage(Class c, Preferences root) {
         // Get the package path
-        String className = o.getClass().getName();
+        String className = c.getName();
         String packagePath;
         int index = className.lastIndexOf('.');
         if(index == -1) {
index f43497894f1e65c853153bd03ecb64f4f4cffdfd..9b2b4129356f8cf32f5af21f21be2b6418bcc30d 100644 (file)
@@ -35,9 +35,8 @@ this exception to your version of the library, but you are not
 obligated to do so.  If you do not wish to do so, delete this
 exception statement from your version. */
 
-package java.util.prefs;
 
-import java.util.EventListener;
+package java.util.prefs;
 
 /**
  * Preferences system and user root factory interface. Defines how to get