src/jdk.jlink/share/classes/jdk/tools/jlink/internal/plugins/SystemModulesPlugin.java
equal
deleted
inserted
replaced
1 /* |
1 /* |
2 * Copyright (c) 2015, 2018, Oracle and/or its affiliates. All rights reserved. |
2 * Copyright (c) 2015, 2019, Oracle and/or its affiliates. All rights reserved. |
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
4 * |
4 * |
5 * This code is free software; you can redistribute it and/or modify it |
5 * This code is free software; you can redistribute it and/or modify it |
6 * under the terms of the GNU General Public License version 2 only, as |
6 * under the terms of the GNU General Public License version 2 only, as |
7 * published by the Free Software Foundation. Oracle designates this |
7 * published by the Free Software Foundation. Oracle designates this |
59 import java.util.stream.Collectors; |
59 import java.util.stream.Collectors; |
60 |
60 |
61 import jdk.internal.module.Checks; |
61 import jdk.internal.module.Checks; |
62 import jdk.internal.module.DefaultRoots; |
62 import jdk.internal.module.DefaultRoots; |
63 import jdk.internal.module.IllegalAccessMaps; |
63 import jdk.internal.module.IllegalAccessMaps; |
|
64 import jdk.internal.module.Modules; |
64 import jdk.internal.module.ModuleHashes; |
65 import jdk.internal.module.ModuleHashes; |
65 import jdk.internal.module.ModuleInfo.Attributes; |
66 import jdk.internal.module.ModuleInfo.Attributes; |
66 import jdk.internal.module.ModuleInfoExtender; |
67 import jdk.internal.module.ModuleInfoExtender; |
67 import jdk.internal.module.ModuleReferenceImpl; |
68 import jdk.internal.module.ModuleReferenceImpl; |
68 import jdk.internal.module.ModuleResolution; |
69 import jdk.internal.module.ModuleResolution; |
289 return generated; |
290 return generated; |
290 } |
291 } |
291 |
292 |
292 /** |
293 /** |
293 * Resolves a collection of root modules, with service binding, to create |
294 * Resolves a collection of root modules, with service binding, to create |
294 * configuration. |
295 * a Configuration for the boot layer. |
295 */ |
296 */ |
296 private Configuration resolve(ModuleFinder finder, Set<String> roots) { |
297 private Configuration resolve(ModuleFinder finder, Set<String> roots) { |
297 return Configuration.empty().resolveAndBind(finder, ModuleFinder.of(), roots); |
298 return Modules.newBootLayerConfiguration(finder, roots, null); |
298 } |
299 } |
299 |
300 |
300 /** |
301 /** |
301 * Returns the list of ModuleInfo objects that correspond to the modules in |
302 * Returns the list of ModuleInfo objects that correspond to the modules in |
302 * the given configuration. |
303 * the given configuration. |