< prev index next >
src/jdk.jdeps/share/classes/com/sun/tools/jdeps/JdepsTask.java
Print this page
*** 384,400 ****
void process(JdepsTask task, String opt, String arg) throws BadArgs {
task.options.includePattern = Pattern.compile(arg);
}
},
- // Another alternative to list modules in --add-modules option
- new HiddenOption(true, "--include-system-modules") {
- void process(JdepsTask task, String opt, String arg) throws BadArgs {
- task.options.includeSystemModulePattern = Pattern.compile(arg);
- }
- },
-
new Option(false, "-P", "-profile") {
void process(JdepsTask task, String opt, String arg) throws BadArgs {
task.options.showProfile = true;
}
},
--- 384,393 ----
*** 1019,1030 ****
// Filter specified by -filter, -package, -regex, and --require options
JdepsFilter.Builder builder = new JdepsFilter.Builder();
// source filters
builder.includePattern(options.includePattern);
- builder.includeSystemModules(options.includeSystemModulePattern);
builder.filter(options.filterSamePackage, options.filterSameArchive);
builder.findJDKInternals(options.findJDKInternals);
// --require
if (!options.requires.isEmpty()) {
--- 1012,1023 ----
// Filter specified by -filter, -package, -regex, and --require options
JdepsFilter.Builder builder = new JdepsFilter.Builder();
// source filters
builder.includePattern(options.includePattern);
+ // target filters
builder.filter(options.filterSamePackage, options.filterSameArchive);
builder.findJDKInternals(options.findJDKInternals);
// --require
if (!options.requires.isEmpty()) {
*** 1042,1056 ****
builder.packages(options.packageNames);
// -filter
if (options.filterRegex != null)
builder.filter(options.filterRegex);
- // check if system module is set
- config.rootModules().stream()
- .map(Module::name)
- .forEach(builder::includeIfSystemModule);
-
return builder.build();
}
public void handleOptions(String[] args) throws BadArgs {
// process options
--- 1035,1044 ----
*** 1160,1182 ****
int depth = 1;
Set<String> requires = new HashSet<>();
Set<String> packageNames = new HashSet<>();
Pattern regex; // apply to the dependences
Pattern includePattern;
- Pattern includeSystemModulePattern;
boolean inverse = false;
boolean compileTimeView = false;
String systemModulePath = System.getProperty("java.home");
String upgradeModulePath;
String modulePath;
String rootModule;
Set<String> addmods = new HashSet<>();
Runtime.Version multiRelease;
boolean hasSourcePath() {
! return !addmods.isEmpty() || includePattern != null ||
! includeSystemModulePattern != null;
}
boolean hasFilter() {
return numFilters() > 0;
}
--- 1148,1168 ----
int depth = 1;
Set<String> requires = new HashSet<>();
Set<String> packageNames = new HashSet<>();
Pattern regex; // apply to the dependences
Pattern includePattern;
boolean inverse = false;
boolean compileTimeView = false;
String systemModulePath = System.getProperty("java.home");
String upgradeModulePath;
String modulePath;
String rootModule;
Set<String> addmods = new HashSet<>();
Runtime.Version multiRelease;
boolean hasSourcePath() {
! return !addmods.isEmpty() || includePattern != null;
}
boolean hasFilter() {
return numFilters() > 0;
}
< prev index next >