--- a/jdk/src/share/classes/com/sun/jmx/namespace/JMXNamespaceUtils.java Tue Sep 09 14:57:30 2008 +0200
+++ b/jdk/src/share/classes/com/sun/jmx/namespace/JMXNamespaceUtils.java Tue Sep 09 17:01:45 2008 +0200
@@ -29,7 +29,6 @@
import java.io.IOException;
import java.util.Collections;
-import java.util.HashMap;
import java.util.Map;
import java.util.WeakHashMap;
import java.util.logging.Level;
@@ -40,6 +39,8 @@
import javax.management.NotificationFilter;
import javax.management.NotificationListener;
import javax.management.event.EventClient;
+import javax.management.event.EventClientDelegateMBean;
+import javax.management.namespace.JMXNamespace;
import javax.management.namespace.JMXNamespaces;
import javax.management.remote.JMXAddressable;
import javax.management.remote.JMXConnector;
@@ -66,26 +67,10 @@
return new WeakHashMap<K,V>();
}
- /** Creates a new instance of JMXNamespaces */
+ /** There are no instances of this class */
private JMXNamespaceUtils() {
}
- /**
- * Returns an unmodifiable option map in which the given keys have been
- * filtered out.
- * @param keys keys to filter out from the map.
- * @return An unmodifiable option map in which the given keys have been
- * filtered out.
- */
- public static <K,V> Map<K,V> filterMap(Map<K,V> map, K... keys) {
- final Map<K,V> filtered;
- filtered=new HashMap<K,V>(map);
- for (K key : keys) {
- filtered.remove(key);
- }
- return unmodifiableMap(filtered);
- }
-
// returns un unmodifiable view of a map.
public static <K,V> Map<K,V> unmodifiableMap(Map<K,V> aMap) {
if (aMap == null || aMap.isEmpty())