8171201: Drop java.compact$N aggregator modules
authormchung
Wed, 14 Dec 2016 10:51:21 -0800
changeset 42817 6545638adc59
parent 42816 3638773ff1b0
child 42818 279d4033e1a8
8171201: Drop java.compact$N aggregator modules 8171202: Rename jdk.crypto.pkcs11 and jdk.pack200 to end with Java letters Reviewed-by: alanb, erikj
langtools/src/jdk.jdeps/share/classes/com/sun/tools/jdeps/Profile.java
--- a/langtools/src/jdk.jdeps/share/classes/com/sun/tools/jdeps/Profile.java	Tue Dec 13 12:25:58 2016 -0800
+++ b/langtools/src/jdk.jdeps/share/classes/com/sun/tools/jdeps/Profile.java	Wed Dec 14 10:51:21 2016 -0800
@@ -39,22 +39,28 @@
  * Build the profile information.
  */
 enum Profile {
-    COMPACT1("compact1", 1, "java.compact1"),
-    COMPACT2("compact2", 2, "java.compact2"),
-    COMPACT3("compact3", 3, "java.compact3", "java.smartcardio", "jdk.sctp",
-                            "jdk.httpserver", "jdk.security.auth",
-                            "jdk.naming.dns", "jdk.naming.rmi",
-                            "jdk.management"),
-    // need a way to determine JRE modules
-    SE_JRE("Java SE JRE", 4, "java.se", "jdk.charsets",
-                            "jdk.crypto.ec", "jdk.crypto.pkcs11",
-                            "jdk.crypto.mscapi", "jdk.crypto.ucrypto",
-                            "jdk.localedata", "jdk.scripting.nashorn", "jdk.zipfs"),
-    FULL_JRE("Full JRE", 5, "java.se.ee", "jdk.charsets",
-                            "jdk.crypto.ec", "jdk.crypto.pkcs11",
-                            "jdk.crypto.mscapi", "jdk.crypto.ucrypto", "jdk.jvmstat",
-                            "jdk.localedata", "jdk.scripting.nashorn",
-                            "jdk.unsupported", "jdk.zipfs");
+    COMPACT1("compact1", 1, "java.logging",
+                            "java.scripting"),
+    COMPACT2("compact2", 2, "java.rmi",
+                            "java.sql",
+                            "java.xml",
+                            "jdk.xml.dom",
+                            "jdk.httpserver"),
+    COMPACT3("compact3", 3, "java.smartcardio",
+                            "java.compiler",
+                            "java.instrument",
+                            "java.management",
+                            "java.naming",
+                            "java.prefs",
+                            "java.security.jgss",
+                            "java.security.sasl",
+                            "java.sql.rowset",
+                            "java.xml.crypto",
+                            "jdk.management",
+                            "jdk.naming.dns",
+                            "jdk.naming.rmi",
+                            "jdk.sctp",
+                            "jdk.security.auth");
 
     final String name;
     final int profile;
@@ -80,12 +86,6 @@
         return JDK.isEmpty() ? 0 : Profile.values().length;
     }
 
-    Optional<Module> findModule(String name) {
-        return modules.containsKey(name)
-            ? Optional.of(modules.get(name))
-            : Optional.empty();
-    }
-
     /**
      * Returns the Profile for the given package name; null if not found.
      */
@@ -137,6 +137,9 @@
 
     // for debugging
     public static void main(String[] args) throws IOException {
+        // initialize Profiles
+        new JdepsConfiguration.Builder().allModules().build();
+
         // find platform modules
         if (Profile.getProfileCount() == 0) {
             System.err.println("No profile is present in this JDK");