< prev index next >

src/jdk.jpackage/share/classes/jdk/jpackage/internal/Arguments.java

Print this page

        

*** 62,72 **** */ public class Arguments { private static final ResourceBundle I18N = ResourceBundle.getBundle( "jdk.jpackage.internal.resources.MainResources"); - private static final String IMAGE_PACKAGE_TYPE = "app-image"; private static final String FA_EXTENSIONS = "extension"; private static final String FA_CONTENT_TYPE = "mime-type"; private static final String FA_DESCRIPTION = "description"; private static final String FA_ICON = "icon"; --- 62,71 ----
*** 375,386 **** public String getId() { return this.id; } String getIdWithPrefix() { ! String prefix = isMode() ? "" : "--"; ! return prefix + this.id; } String getShortIdWithPrefix() { return this.shortId == null ? null : "-" + this.shortId; } --- 374,384 ---- public String getId() { return this.id; } String getIdWithPrefix() { ! return "--" + this.id; } String getShortIdWithPrefix() { return this.shortId == null ? null : "-" + this.shortId; }
*** 391,404 **** } else { defaultAction(); } } - boolean isMode() { - return category == OptionCategories.MODE; - } - OptionCategories getCategory() { return category; } private void defaultAction() { --- 389,398 ----
*** 422,442 **** private static void nextArg() { context().pos++; } - private static void prevArg() { - context().pos--; - } - private static boolean hasNextArg() { return context().pos < context().argList.size(); } } enum OptionCategories { - MODE, MODULAR, PROPERTY, PLATFORM_MAC, PLATFORM_WIN, PLATFORM_LINUX; --- 416,431 ----
*** 539,549 **** } private void validateArguments() throws PackagerException { String packageType = deployParams.getTargetFormat(); String ptype = (packageType != null) ? packageType : "default"; ! boolean imageOnly = IMAGE_PACKAGE_TYPE.equals(packageType); boolean hasAppImage = allOptions.contains( CLIOptions.PREDEFINED_APP_IMAGE); boolean hasRuntime = allOptions.contains( CLIOptions.PREDEFINED_RUNTIME_IMAGE); boolean installerOnly = !imageOnly && hasAppImage; --- 528,538 ---- } private void validateArguments() throws PackagerException { String packageType = deployParams.getTargetFormat(); String ptype = (packageType != null) ? packageType : "default"; ! boolean imageOnly = (packageType == null); boolean hasAppImage = allOptions.contains( CLIOptions.PREDEFINED_APP_IMAGE); boolean hasRuntime = allOptions.contains( CLIOptions.PREDEFINED_RUNTIME_IMAGE); boolean installerOnly = !imageOnly && hasAppImage;
*** 692,705 **** fileNames.forEach(file -> deployParams.addResource(baseDir, file)); deployParams.setClasspath(); } - static boolean isCLIOption(String arg) { - return toCLIOption(arg) != null; - } - static CLIOptions toCLIOption(String arg) { CLIOptions option; if ((option = argIds.get(arg)) == null) { option = argShortIds.get(arg); } --- 681,690 ----
< prev index next >